(A) [15 points] Write a recursive function that will calculate Fibonacci numbers using a recursive
definition. Write a short program to test it. The input of this program must be a positive integer
n; the output is the corresponding Fibonacci number F(n).
(B) [20 points] Write an iterative function to calculate Fibonacci numbers. Write a test driver for it.
The input of this program must be a positive integer n; the output is the corresponding Fibonacci
(C) [10 points] Write a program that will compare running time of the recursive and iterative
functions for calculating Fibonacci numbers. Call each function for the same size of input n and
find their running times. For part (E) of this project you will have to run this program multiple
times to find out how the running time of each function depends on the value of n.
(D)[35 points] NOT RELEVANT TO PREVIOUS PARTS.
In this part of the project, write a function that will implement each Fibonacci number with the
help of an integer array of size 100 (elements of this array will be digits of the Fibonacci
number). When the function is called to find F(n), it will calculate all Fibonacci numbers from
F(2) to F(n). using the basic formula F(n) = F(n-1)+F(n-2). To add two Fibonacci
numbers, the function will add elements of two arrays corresponding to F(n-1) and F(n-2)
and store their sums in the array corresponding to F(n). (You are NOT supposed to store ALL
arrays.) Write a program that will calculate Fibonacci numbers containing up to 100 digits.
Display the biggest Fibonacci number that has less than 100 digits. Make sure that your program
will display the error message when a Fibonacci number has 100 digits or more.
(E) [20 points] This part of the project is a written analysis of two algorithms of calculating
Fibonacci numbers: recursive (part A) and iterative (part B). Show the theoretical order of
growth of the running time for both algorithms. Then include experimental results based on part
(C) and explain them.
Hello, I'm expert in JAVA, python and C. I have a M Sc degree in AI and extensive experience in problem solving, so I can easily help you. Looking forward to your reply.
11 freelancers estão ofertando em média $23 nesse trabalho
Hi ! I have read all your description. I am professional Java developer. I am sure high quality, good communication. Please contact me and Lets go ahead ! Thanks.
Hello sir Greetings from Tech Vocal I am a good programmer and I can do this work too and also I have good developers too We have good experience in this field Please message me for further discussion
Hello sir/madam... I can solve your recursion problem in 1 day. Please state which programming language to use (I suppose Java or C++). Any of them is good. Please, contact me to make deal. Regards Vladimir