how to generate fibonacci series (lesser than 100)
how to generate fibonacci series (lesser than 100)
Collapse
X
-
Comment
-
The OP may need help getting a C/C++ program to do his bidding but he ought to be able to describe what the program should do (in this case, the Fibonacci Series). Laying out the necessary equations fully and methodically often suggests a good structure for the program.Comment
-
I was confused whether OP wanted us, to write the program for him or he is asking for design help? Its hard to figure it out through this question. :)
Regards
Dheeraj JoshiComment
-
-
No. You want to display the Fibonacci Series up to, but not including, the first term that is greater than 100. It just so happens that this means the last term displayed will be 89, but that magic number should not be hard-coded into your program. To include that number in your program requires you to solve the problem (to discover "89") before you write a program to solve the problem.
By the way, you haven't provided the mathematical equations that define a Fibonacci Series.Comment
Comment