2 50 Points Write Function Calculates Fibonacci Numbers 1 40 Xn N 1 2 40 Rl Example X2 X1 Q37212192

2. [50 points] Write a function that calculates Fibonacci numbers from 1 to 40, xn, n- 1,2,...40: rl For example:X2-X1 + Xo =

language is c++

2. [50 points] Write a function that calculates Fibonacci numbers from 1 to 40, xn, n- 1,2,…40: rl For example:X2-X1 + Xo = 1 + 0 = 1. Show transcribed image text 2. [50 points] Write a function that calculates Fibonacci numbers from 1 to 40, xn, n- 1,2,…40: rl For example:X2-X1 + Xo = 1 + 0 = 1.


Answer


#include <iostream>
using namespace std;
void fibCalculation()
{
for(int n=0;n<=40;n++)//this loop indicate n

OR
OR

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.