Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

raganwald/FRACTRAN

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FRACTRAN

John Horton Conway at the blackboard

A FRACTRAN interpreter, in honour of John Horton Conway.

setup and running the examples

Prerequisites:

Installing Babel to compile ES-whatever to node-whatever:

npm install --save-dev @babel/core @babel/cli @babel/preset-env
npm install --save @babel/polyfill

Print an infinite list of primes using a big integer implementation:

npx babel src --out-dir lib && node ./lib/integer-primes.js
  => 2
     3
     5
     7
     11
     13
     17
     19
     23
     29
     ...

Or limit the number of primes:

npx babel src --out-dir lib && node ./lib/integer-primes.js 7
  => 2
     3
     5
     7
     11
     13
     17

Or compute an arbitrary fibonacci number:

npx babel src --out-dir lib && node ./lib/integer-fib.js 7
  => fib(7) = 13

More...

Building Fizzbuzz in Fractran from the Bottom Up

HashLife, in the browser

Gosper’s HashLife in Literate CoffeeScript

About

Code to accompany “ Remembering John Conway's FRACTRAN, a ridiculous, yet surprisingly deep language”

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.