斐波那契数列

递归算法
def Fab(num):
	if num==1 or num==2: return 1
	return Fab(num-1)+Fab(num-2)
非递归算法
# still not work; out of index on list
# work now,but improvement is need.
def Fab(num):
	Fab=range(num+1)
	Fab[0]=0
	Fab[1]=1
	Fab[2]=1
	for i in range(3,num+1):
		Fab[i]=Fab[i-1]+Fab[i-2]
	return Fab[num]