#include <stdio.h>
int main()
{
int a[105]={1,1};
int i,x;
while(scanf("%d",&x)!=EOF)
{
if(x==0)
printf("f(0)=%d\n",x);
else if(x==1)
printf("f(1)=%d\n",x);
else
{
for(i=2;i<=x;i++)
{
a[i]=a[i-1]+a[i-2];
printf("f(%d)=%d\n",i,a[i]);
}
}
}
return 0;
}
试试行不