About
An interpreter written in Ruby for the imperative, stack based language called Whitespace.
Installation
Install it yourself using:
$ gem install whitespace-rubyYou would now have access to an executable called whitespace. Type
$ whitespace --helpto learn more.
Usage
Let's say you've written a Whitespace program and stored it in the file program.ws. Then, to execute that program, type:
$ whitespace program.wsThis gem comes with example Whitespace programs that you can check out at examples. Be sure to run them to see what they do.
For example, here's the factorial program and a sample execution (assuming you're in the examples directory):
$ whitespace fact.ws
Enter a number: 40
40! = 20397882081197443358640281739902897356800000000References
Credits
Thanks to Edwin Brady and Chris Morris for developing this programming language (also developers of the Idris programming language). I've had lots of fun playing with it and writing interpreters (in Racket, Haskell and now Ruby) for it.
Copyright
Copyright (c) 2016 Dwayne Crooks. See LICENSE for further details.