# Program to compute the first 20 numbers of the Fibonnaci series # Matt Bishop, Feb. 17, 2012 # for ECS 10 Winter 2012 def fib(n): if n == 0: return 0 elif n == 1: return 1 else: return fib(n-1) + fib(n-2) def main(): # say how many numbers are to be printed count = 20 # compute the sequence and print the terms for i in range(count-2): # get next Fibonnaci number and # announce it print("Fibonnaci number", i+1, "is", fib(i)) main()