Skip to content

Instantly share code, notes, and snippets.

@sepulworld
Created November 9, 2017 20:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sepulworld/764fd7fb4da030981388a87c55530a2a to your computer and use it in GitHub Desktop.
Save sepulworld/764fd7fb4da030981388a87c55530a2a to your computer and use it in GitHub Desktop.
Fibonacci_list
def fibonacci(max):
x, y = 0, 1
while x < max:
yield x
x, y = y, x + y
fib_list = [n for n in fibonacci(1000)]
print("here is the fib_list: {}".format(fib_list))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment