diff options
-rw-r--r-- | examples/fib.ash | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/examples/fib.ash b/examples/fib.ash index bf2b90d..c29476d 100644 --- a/examples/fib.ash +++ b/examples/fib.ash @@ -1,14 +1,14 @@ # Print out given number of elements in the Fibonacci sequence, 46 is the max value define fib - var lim push lim - var a 1 push a - var b 1 push b - pull lim while dup 0 > do - pull a dump - pull b dup - pull a - + push b - push a + var lim !lim + var a 1 !a + var b 1 !b + @lim while dup 0 > do + @a dump + @b dup + @a + + !b + !a 1 - done end |