Last Update: 5:25pm Fri., 2/11.
Fibonacci numbers. The Fibonacci Sequence is
1,1,2,3,5,8,13,21,.... It can be defined by the following
three rules.
F(1) = 1.
F(2) = 1.
F(i) = F(i-1) + F(i-2) for every integer i > 2.
Implement a C++ function that computes the ith
Fibonacci number F(i), for any user-specified i >= 1.
Make sure that your solution uses a constant amount of storage and
a total number of arithmetic operations proportional to input i.
This restatement starts the indexing at 1 instead of 0, to simplify
the language. You may use either form of the definition
(start at 0, or start at 1).