public class demo3 {
public static void main(String[] args) {
int mouth=1;
while(true){
System.out.println("第"+mouth+"月的"+"兔子的总数为"+brith(mouth));
mouth++;
}
}
public static int brith(int mouth){
if (mouth<3){
return 1;
}
else{
return brith(mouth-1)+brith(mouth-2);
}
}
}