【十二题解】 | #统计每个月兔子的总数#
统计每个月兔子的总数
http://www.nowcoder.com/practice/1221ec77125d4370833fd3ad5ba72395
#include<stdio.h>
int fib(int a){
if (a==1)return 1;
if(a==2)return 1;
return fib(a-1)+fib(a-2);
}
int main(){
int number;
while(scanf("%d", &number) != EOF)printf("%d\n", fib(number));
}