using System;
class myclass
{
static void Main()
{
int fn = 0;
int sn = 1;
int tn = 1;
Console.WriteLine(fn);
Console.WriteLine(sn);
while (true)
{
tn = fn + sn;
if (tn >= 100)
{
break;
}
Console.WriteLine(tn);
fn = sn;
sn = tn;
}
Console.Read();
}
}
|
C# | ASP.Net | MVC | SQL Server | jQuery | Java Script | LINQ | SSRS| Web Application | Bootstrap | Kendo
Thursday, 16 October 2014
Program to print Fibonacci Numbers below 100 in c#
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment