题目链接·
http://acm.hdu.edu.cn/showproblem.php?pid=2046
#include<bits/stdc++.h>
using namespace std;
long long a[80];
int main(void)
{
int n,k;
a[0] = 0;
a[1] = 1;
a[2] = 2;
for (int i=3;i<80; i++)
{
a[i] = a[i-1] + a[i-2];
}
while (scanf("%d", &k)!=EOF)
{
printf("%lld\n", a[k]);
}
return 0;
}