Last active
July 2, 2017 17:28
-
-
Save theWhiteFox/0e0382363fc1a8a4a3ffcca7ccf31b82 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
"use strict"; | |
// below functions can be accessed from the console | |
// very basic fibonacci | |
function basicFib() { | |
var first = 1, | |
second = 0, | |
answer = first + second; | |
while(answer < 100) { | |
console.log(answer); | |
second = first; | |
first = answer; | |
answer = first + second; | |
} | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment