educative.io

Educative

Error exercise-fibonacci-series__loop

The fibonacci number of 7 is 13 not 8.
The error is when assigning 0 to fibonacci number of 1! It is 1.

Please update solution
Thanks Jim

The Fibonacci series starts with 0. It is as follows: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55…
Hence Fib(7) is equal to 8 and not 13