diff options
Diffstat (limited to 'samples/variables.slam')
| -rw-r--r-- | samples/variables.slam | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/samples/variables.slam b/samples/variables.slam new file mode 100644 index 0000000..8902b04 --- /dev/null +++ b/samples/variables.slam @@ -0,0 +1,13 @@ +-- store foo = 10 +10 $foo ! + +-- load and print foo +$foo ? + +-- print 1 + value at foo +1 $foo @ + . + +-- define x * 2 = x + x +define *2 dup + ; + +666 *2 . |
