`for`

loop is that, after each iteration, `b`

is set to the `i`

th Fibonacci number, and `a`

is set to the (`i`

-1)th Fibonacci number.
The more obvious recursive definition is bad because you end up repeating a lot of work. For example, `fibonacci(10)`

would need to compute `fibonacci(8)`

and `fibonacci(9)`

, but `fibonacci(9)`

ends up calling `fibonacci(8)`

as well. You end up running in O(φ^{n}) because of all the repeated work, instead of O(`n`) like the iterative implementation, which only computes each intermediate Fibonacci number once.