You are viewing a single comment's thread. Return to all comments →
It's weird to me that the Fibonacci sequence is academically used as the "hello world" of recursion because I mean:
def fibonacci(n): if n == 1: return(1) upper = 1 lower = 1 for i in range(2,n): upper, lower = lower + upper, upper return(upper)
Seems like cookies are disabled on this browser, please enable them to open this website
Recursion: Fibonacci Numbers
You are viewing a single comment's thread. Return to all comments →
It's weird to me that the Fibonacci sequence is academically used as the "hello world" of recursion because I mean: