Added handling of string case for 0

This commit is contained in:
Miko
2023-09-18 23:01:33 +02:00
committed by GitHub
parent 85a9d56fde
commit f2c0d0955b
+1 -1
View File
@@ -1,6 +1,6 @@
const fibonacci = function(count) {
if (count < 0) return "OOPS";
if (count === 0) return 0;
if (count == 0) return 0;
let firstPrev = 1;
let secondPrev = 0;