Count the number of sequences of 1-unit and 2-unit jumps whose total distance is \(n\).
Let \(a_n\) be the number of ordered sequences consisting of jumps of size \(1\) and \(2\) whose total is \(n\).
Why? Every valid sequence must end in exactly one of two ways:
Remove the final \(1\). The remaining sequence must sum to \(n-1\).
Remove the final \(2\). The remaining sequence must sum to \(n-2\).
| \(n\) | 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
|---|---|---|---|---|---|---|---|---|---|
| \(a_n\) | |||||||||
| \(F_{n+1}\) |
The standard Fibonacci sequence satisfies
Therefore
These match our initial values
Both sequences have the same initial values and obey the same recurrence, except that the Fibonacci indices are shifted by one.