Question: Question 3: Please give a) and b) answer. Thanks. The Fibonacci sequence is the series of numbers: 0, 1, 1, 2, 3, 5, 8, 13,
Question 3: Please give a) and b) answer. Thanks.

The Fibonacci sequence is the series of numbers: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, ... The next number is found by adding up the two numbers before it. The 2 is found by adding the two numbers before it (1+1) The 3 is found by adding the two numbers before it (1+2) And the 5 is (2+3), and so on! Write an algorithm which would be able to get two input numbers, n and P and process the following requirements: (a) If the first three Fibonacci numbers are given as 1, 1 and 2, then what is the n-th number? Find the number value. (b) If the first three Fibonacci numbers are given as x_1 = 1, x_2 = 1 and x_3 = 2, then what is the least value of n for which x_n > P? Find the n value
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
