Update fibonacci.js

This commit is contained in:
Cody Loyd 2020-01-29 10:52:57 -06:00 committed by GitHub
parent abcaeb918a
commit 3b51e5dbef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 0 deletions

View File

@ -1,5 +1,6 @@
const fibonacci = function(count) {
if (count < 0) return "OOPS";
if (count == 0) return 0;
let a = 0;
let b = 1;
for (let i = 1; i < count; i++) {