Created
June 25, 2017 22:45
-
-
Save dmlap/c8e489ea6d5c860a6d304125f2d7e21d to your computer and use it in GitHub Desktop.
Recursively generate the Fibonacci sequence. (This loops forever since javascript is eagerly evaluated)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function fibonnaci(n0, n1) { | |
let n2 = n0 + n1 | |
console.log(n2) | |
return fibonnaci(n1, n2) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment