mirror of
https://github.com/donnemartin/interactive-coding-challenges.git
synced 2024-03-22 13:11:13 +08:00
Tweaked fibonacci algorithm discussion.
This commit is contained in:
parent
d4a2300ea0
commit
84ab643587
|
@ -55,6 +55,7 @@
|
|||
"source": [
|
||||
"## Algorithm\n",
|
||||
"\n",
|
||||
"Recursive:\n",
|
||||
"* Fibonacci is as follows: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34...\n",
|
||||
"* If n = 0 or 1, return n\n",
|
||||
"* Else return fib(n-1) + fib(n+2)\n",
|
||||
|
|
Loading…
Reference in New Issue
Block a user