The Fibonacci algorithm is a famous mathematical function that allows us to create a sequence of numbers by adding together the two previous values. For example, we have the sequence:
1, 1, 2, 3, 5, 8, 13, 21… (this means F1=1, F2=1, F3=2,...)
Write your own recursive code to calculate the nth (i.e. Fn) term in the sequence. You should accept a positive integer as an input, and output the nth term of the sequence.
Once you have created your code, add comments describing how the code works, and the complexity of any code you have created.
Note 1: you must get the input number from the user.
Note 2: In many references F0 is also defined as 0. However, for this assignment assume the sequence starts from F1.