# Program to compute the first 20 numbers of the Fibonnaci series
# Matt Bishop, Apr. 7, 2009
# for ECS 10 Spring 2009
def main():
# say how many numbers are to be printed
count = 20;
# initialize series
fn2 = 0;
fn1 = 1;
print "Fibonnaci number 1 is", fn2;
print "Fibonnaci number 2 is", fn1;
# compute the sequence and print the terms
for i in range(count-2):
# get next Fibonnaci number
fn = fn1 + fn2;
# announce it
print "Fibonnaci number", i+3, "is", fn;
# advance in seuence
fn2 = fn1;
fn1 = fn;
main()