using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace 斐波那契数列
{
class Program
{
static void Main(string[] args)
{
int a = 0;
int b = 1;
int c=0;
while(c<89)
{
c = a + b;
a = c ;
b = a-b;
Console.WriteLine(c);
}
Console.ReadLine();
}
}
}
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace 斐波那契数列
{
class Program
{
static void Main(string[] args)
{
int a = 0;
int b = 1;
int c=0;
while(c<89)
{
c = a + b;
a = c ;
b = a-b;
Console.WriteLine(c);
}
Console.ReadLine();
}
}
}