Skip to content

Instantly share code, notes, and snippets.

@fuwiak
Created October 25, 2020 16:13
Show Gist options
  • Save fuwiak/9a69e35bb19d31abd0504b6db1ae55cc to your computer and use it in GitHub Desktop.
Save fuwiak/9a69e35bb19d31abd0504b6db1ae55cc to your computer and use it in GitHub Desktop.
def fibonacci(n):
def recur_fibo(n):
if n <= 1:
return n
else:
return(recur_fibo(n-1) + recur_fibo(n-2))
if n <= 0:
print("Plese enter a positive integer")
else:
for i in range(n):
print(recur_fibo(i))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment