Page 1 of 1

StdID: 252185 Question 1: 2 Marks The Fibonacci sequence defined by F=1,1,2,3,5,8,13,21,34,55,89....N where the ith term

Posted: Fri May 20, 2022 4:45 pm
by answerhappygod
Stdid 252185 Question 1 2 Marks The Fibonacci Sequence Defined By F 1 1 2 3 5 8 13 21 34 55 89 N Where The Ith Term 1
Stdid 252185 Question 1 2 Marks The Fibonacci Sequence Defined By F 1 1 2 3 5 8 13 21 34 55 89 N Where The Ith Term 1 (56.56 KiB) Viewed 52 times
Stdid 252185 Question 1 2 Marks The Fibonacci Sequence Defined By F 1 1 2 3 5 8 13 21 34 55 89 N Where The Ith Term 2
Stdid 252185 Question 1 2 Marks The Fibonacci Sequence Defined By F 1 1 2 3 5 8 13 21 34 55 89 N Where The Ith Term 2 (56.56 KiB) Viewed 52 times
StdID: 252185 Question 1: 2 Marks The Fibonacci sequence defined by F=1,1,2,3,5,8,13,21,34,55,89....N where the ith term is given by F = F-1 + F1-2 Code has already been provided to define a function named fibGen that accepts a single input into the variable N. Add code to the function that uses a for loop to generate the Nth term in the sequence and assign the value to the output variable fib with an unsigned 32-bi integer datatype. Assume the input N will always be greater than or equal to 4. Note the value of N (SUID) is defined as an input to the function. Do not overwrite this va in your code. Be sure to assign values to each of the function output variables. Use a for loop in your answer. a