112358132134 求第30 个数是多少用C#代码实现
int n = 30;
int a = 1;
int b = 1;
int c = 0;
for(int i = 3; i <= n; i++)
{
c = a + b;
a = b;
b = c;
}
Console.WriteLine(c);
输出结果为: 1346269
原文地址: https://www.cveoy.top/t/topic/Z95 著作权归作者所有。请勿转载和采集!
安全问答是一个知识全球问答,包含丰富的问答知识
int n = 30;
int a = 1;
int b = 1;
int c = 0;
for(int i = 3; i <= n; i++)
{
c = a + b;
a = b;
b = c;
}
Console.WriteLine(c);
输出结果为: 1346269
原文地址: https://www.cveoy.top/t/topic/Z95 著作权归作者所有。请勿转载和采集!