lizhuoxiang110
发表于 2021-5-11 13:22:21
查看参考答案
yuml170
发表于 2021-5-11 16:09:12
{:10_257:}
叱咤风云
发表于 2021-5-11 17:23:35
#include <stdio.h>
int main()
{
float jiayu=10000, heiye=10000;
int year=0;
while (jiayu >= heiye)
{
jiayu=jiayu+1000;
heiye=heiye*1.05;
year++;
}
printf("%d年后,黑夜的资产超过小甲鱼\n",year);
printf("小家鱼的投资额为:%.2f\n",jiayu);
printf("黑夜的投资额为:%.2f\n",heiye);
return 0;
}
#include<stdio.h>
int main()
{
float money=4000000;
int year=0;
while (money>=0)
{
money-=500000;
money*=1.08;
year++;
}
printf("%d年后,资产败光",year);
}
#include<stdio.h>
int main()
{
int rabbit, adult=2, baby_0=0, baby_1=0,month,a ;
for(month=1;month<=12;month++)
{
a=adult;
adult=adult+baby_1;
baby_1=baby_0;
baby_0=a;
}
rabbit=adult+baby_0+baby_1;
printf("%d", rabbit);
return 0;
}
我喜欢毛毛呀
发表于 2021-5-11 20:00:58
hh
yuml170
发表于 2021-5-11 21:19:54
图不对啊,不是两个月才能下崽吗?怎么第三个月的时候第二个月的兔子都开始下崽了
{:10_261:}
xbm0506
发表于 2021-5-11 22:27:33
xbm
酷酷富
发表于 2021-5-12 15:22:45
看一看
张良坤
发表于 2021-5-12 17:26:03
1
张良坤
发表于 2021-5-12 17:33:05
/*if (size > 12)
{
i=1;
}
if(i=1)
{
cost = cost * 1.05;
flag = 2;
}
bill = cost * flag;
*/
/*if (ibex > 14)
{
a=1;
}
if(a != 1)
{
sheds = 2;
b = 1;
}
if(b !=1)
{
a: sheds = 3;
}
b: help = 2 * sheds;
*/
/*
do
{
readin: scanf("%d", &score);
if (score < 0)
{
break;
}
count++;
}while(1);
stage2: printf("count = %d\n", count);
*/
/*
#include<stdio.h>
int main()
{
int i;
float ch = 10000;
float num = 10000;
for(i = 1;num >= ch;i++)
{
num = 10000 + 10000 * (float)(0.1 * i);
ch = ch + ch * (float)0.05;
}
i--;
printf("%d年后黑夜的投资额超过了小甲鱼\n",i);
printf("小甲鱼的投资额是%.2f\n",num);
printf("黑夜的投资额是%.2f\n",ch);
return 0;
}*/
/*#include<stdio.h>
int main()
{
double ch=4000000;
float num;
int i;
for(i = 0;ch > 0;i++)
{
ch -=500000;
ch = ch + ch * 0.08;
}
printf("%d年后小甲鱼穷了\n",i);
return 0;
}*/
/*
#include<stdio.h>
#include<math.h>
int main()
{
int j;
unsigned long int i;
long double ch = 1;
signed int num = -3;
for(i = 1;i < 100;i++)
{
ch = ch + 1 / num;
for(j = 1;j = 1;j++)
{
ch = ch + 1 / num;
num = fabs(num) + 2;
}
num = -num - 2;
}
ch = 4 * ch;
printf("pi=%.7lf\n",ch);
return 0;
}
*/
/*#include<stdio.h>
int main()
{
int i;
int a = 0;
int b = 0;
int c = 1;
int num;
for(i = 2;i <= 24;i++)
{
c = c + b;
b = a;
a = c;
}
i = 2 * (a + b + c) ;
printf("两年后有%d只兔子\n",i);
return 0;
}
mmengma
发表于 2021-5-12 17:39:36
0.10次
1.10次
2.c,b,a
3.a=16;b=6;c=10
4. x>=0?z=x:z=-x;
5.
A.
if (size > 12)
{
cost = cost * 1.05;
flag = 2;
}
bill = cost * flag;
B.
if (ibex > 14)
{
sheds = 3;
}
sheds = 2;
help = 2 * sheds;
C.
if (score < 0)
{
printf("count = %d\n", count);
}
count++;
scanf("%d", &score);
Rox
发表于 2021-5-12 23:18:48
dd
clay_sun
发表于 2021-5-13 08:24:41
对答案
chc2001
发表于 2021-5-13 09:51:45
1
romeos
发表于 2021-5-13 17:43:16
looklook
Godsplan
发表于 2021-5-14 19:17:13
1111
jx938299598
发表于 2021-5-14 21:27:05
..
DylanBee
发表于 2021-5-14 21:51:17
fdsdafsdafdsfadsfa
梵天99
发表于 2021-5-15 06:04:49
2
村长有话说
发表于 2021-5-15 07:28:02
顶
略略略UR
发表于 2021-5-15 12:45:52
q