5. Programming Questions:
a) Define the function UpHeap that will take an array A of integers, number of data in the array N and the index of the point where UpHeap is applied I as inputs, and the function should illustrate the UpHeap Operation
b) Given the Fibonacci number algorithm as below:
For an integer N, the Fibonacci number is computed as:
If N is 0 or 1, return N
Otherwise return the sum of Fibonacci number at N-1 and N-2
Write this function in C++, using recursive concept.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here