Question: write a c + + program. Program 2 < 3 0 points > : Fibonacci numbers ( fibonacci . cpp ) Write a program that

write a c++ program. Program 2<30 points>: Fibonacci numbers (fibonacci.cpp)
Write a program that will show Fibonacci numbers (011235813...). The program should ask for the
number of Fibonacci numbers the user wants to see (N >=3). You need to reject invalid numbers that are
less than 3. Once the user enters a valid N, it will show the first N fibonacci numbers.
Note: Dont use recursion (if you know), which is a technique that will be covered in CS211.
[kslott@empress cs111_lec_fall16]$ ./a.out
Enter the number of fibonacci numbers you want to see (N >=3): 1 rejected
Enter the number of fibonacci numbers you want to see (N >=3): 2 rejected
Enter the number of fibonacci numbers you want to see (N >=3): 3
011
[kslott@empress cs111_lec_fall16]$ ./a.out
Enter the number of fibonacci numbers you want to see (N >=3): 10
0112358132134
[kslott@empress cs111_lec_fall16]$ ./a.out
Enter the number of fibonacci numbers you want to see (N >=3): 20
01123581321345589144233377610987159725844181
[kslott@empress cs111_lec_fall16]$

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!