Help me with a fibonacci sequence function in C++
Implement the function FastFib that on input n outputs the n-th term of the
Fibonacci number. Your running time must be within O(log n) by using any method. The Fibonacci numbers are defined as
fn = {1 n = 1, 2}
{f sub n-1 + f sub n-2 n>= 3 }
Here you can assume that there is no integer overflow.