Answered by:
fibonacci series c#
Question
Answers

int oldn=0;
int newno=1;
int fno;
int j=0;
for(; ;)
{fno=oldn+newno;
newno=fno;
oldn=newno;
j++;
if(j<4)
{
break;
}
Console.writeline(oldn,newno,fno);
}
easiest method made for you by me.
 Edited by techmania Saturday, February 12, 2011 12:46 PM some text missing
 Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM

Hi,
I have some problems to understand your problem. Can you please help a little more? My answer at the moment would be:
Console.Write("0 1 1 2 3");
which writes a list of the first 5 fibonacci numbers  as you requested.
Sorry, at the moment I have simply the feeling that this is a question like "Please do my homework". At least I will not write complete solutions in such cases. Target of a homework is, that you learn something. So please tell me, where you have a problem?
 Do you need information about the fibonacci series? http://en.wikipedia.org/wiki/Fibonacci_number
 Do you need to know how to write a program? Or you miss software? http://windowsclient.net could be a good start.
 Do you need information about methods or loops? Or maybe you want to learn about recursion?
Just tell us, what your problem really is and we will try to help you.
With kind regards,
Konrad
 Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM

There is an example of Fibonacci at this link.
http://msdn.microsoft.com/enus/library/system.componentmodel.backgroundworker.aspx
Rudy =8^D
Mark the best replies as answers. "Fooling computers since 1971." Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM
All replies

int oldn=0;
int newno=1;
int fno;
int j=0;
for(; ;)
{fno=oldn+newno;
newno=fno;
oldn=newno;
j++;
if(j<4)
{
break;
}
Console.writeline(oldn,newno,fno);
}
easiest method made for you by me.
 Edited by techmania Saturday, February 12, 2011 12:46 PM some text missing
 Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM

Hi,
I have some problems to understand your problem. Can you please help a little more? My answer at the moment would be:
Console.Write("0 1 1 2 3");
which writes a list of the first 5 fibonacci numbers  as you requested.
Sorry, at the moment I have simply the feeling that this is a question like "Please do my homework". At least I will not write complete solutions in such cases. Target of a homework is, that you learn something. So please tell me, where you have a problem?
 Do you need information about the fibonacci series? http://en.wikipedia.org/wiki/Fibonacci_number
 Do you need to know how to write a program? Or you miss software? http://windowsclient.net could be a good start.
 Do you need information about methods or loops? Or maybe you want to learn about recursion?
Just tell us, what your problem really is and we will try to help you.
With kind regards,
Konrad
 Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM

There is an example of Fibonacci at this link.
http://msdn.microsoft.com/enus/library/system.componentmodel.backgroundworker.aspx
Rudy =8^D
Mark the best replies as answers. "Fooling computers since 1971." Marked as answer by Leo Liu  MSFTModerator Saturday, February 19, 2011 2:26 AM

This is an example for printing Fibonacci numbers
http://www.programcall.com/6/interview/programtoprintfibonaccinumbersbelow100.aspx
 Proposed as answer by P V Ananda Sai Charan Tuesday, October 08, 2013 2:50 AM