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

Related Python Mentoring answers

All answers ▸

Write a program that can convert between celcius and farenheit temperature scales


What is the difference between a for and a while loop?


What is the difference between a for loop and a while loop.


Sort a given input of lowercase letters alphabetically