还是有点看不太懂
#include <stdio.h>
int a(any)
{
int age;
if(any==1)
age=10;
else
age=a(any-1)+2;
return age;
}
int main()
{
int an=a(5);
printf("第5个人的年龄是%d岁",an);
return 0;
}
int a(any)
{
int age;
if(any==1)
age=10;
else
age=a(any-1)+2;
return age;
}
int main()
{
int an=a(5);
printf("第5个人的年龄是%d岁",an);
return 0;
}