Example pasted by Nobody, 10:44 August 22nd

‣ New

Syntax: Python
    ‣ Plain   ‣ HTML   ‣ Copy
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
# fibonacci generator code from diveintopython.org

def fibonacci(max):
    a, b = 0, 1
    while a < max:
        yield a
        a, b = b, a+b

for n in fibonacci(1000):
    print n,
This item will be deleted in 3000 days
URL: http://dpaste.com/example/
‣ About this site