No. It does not mention the base cases.
A recursive definition (or program) must have two parts:
Fibonacci Series | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
N | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
fib(N) | 1 | 1 | 2 | 3 | 5 | 8 | 13 | 21 | 34 | 55 |
Here is an expanded version of fib(N)
:
The rule seems to be plagued with blanks. Can you fill them?