previous numbers fibonacci sequence python code example
Example: fibonacci series in python
#Recursive Solutions
def fibo(n):
if n<=1: return 1
return fibo(n-1)+fibo(n-2)
fibo(5)
#OUTPUT:
#120
#Recursive Solutions
def fibo(n):
if n<=1: return 1
return fibo(n-1)+fibo(n-2)
fibo(5)
#OUTPUT:
#120