Skip to content

Instantly share code, notes, and snippets.

@wegorich
Created August 21, 2014 13:43
Show Gist options
  • Save wegorich/0ac26eb71ea9288550a6 to your computer and use it in GitHub Desktop.
Save wegorich/0ac26eb71ea9288550a6 to your computer and use it in GitHub Desktop.
simple fib function
def fib(n):
a, b = 0, 1
while a < n:
print(a)
a, b = b, a+b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment