Answers
>
Python
>
Mentoring
>
Article
Write a recursive function to return the nth Fibonacci number in Python
def fibonacci(n): if n <= 1: return n else: return fibonacci(n-1) + fibonacci(n-2)
FG
Answered by
Finn G.
•
Python tutor
1966 Views
See similar Python Mentoring tutors
Related Python Mentoring answers
All answers ▸
How do you define a class in python
What can be used to iterate through a list in python?
How does a for loop work in Python?
What is the difference between a FOR loop and WHILE loop and how do I write them?