Skip to content

Instantly share code, notes, and snippets.

@devnoo
Created November 27, 2011 09:05
Show Gist options
  • Save devnoo/1397272 to your computer and use it in GitHub Desktop.
Save devnoo/1397272 to your computer and use it in GitHub Desktop.
fibonaci-recursive
fib := method(n,
if (n <= 2, return 1, return fib(n - 1) + fib(n - 2))
)
for (i, 1, 25, fib(i) println)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment