hrivenboy
发表于 2024-8-5 13:48:50
好评!
学C的h
发表于 2024-8-6 10:15:47
1
陈东豪
发表于 2024-8-6 15:53:05
1
徐长卿ovo
发表于 2024-8-6 17:21:24
知识忘了好多啦{:10_284:}
变西瓜
发表于 2024-8-15 15:49:29
查看
不胜土豆
发表于 2024-8-15 16:01:43
1
kongchwng2
发表于 2024-8-17 17:14:22
16
学程序真快乐
发表于 2024-8-18 12:27:44
1
希儿的
发表于 2024-8-20 18:23:07
0.11次
1.哈哈刚错过,0 次!
2.a b c都是
3. b=3 b=4 c=9?c=10 b=5 a=15? 感觉不对
4.
#include <stdio.h>
int main()
{
int i;
printf("请输入一个数");
scanf_s("%d", &i);
if (i < 0)
{
i = -i;
}
printf("i 的绝对值是 :%d", i);
return 0;
}
5.
A.
int size, flag, cost, bill;
if (size > 12)
{
cost = cost * 1.05;
flag = 2;
}
bill = cost * flag;
B.
if (ibex > 14)
{
sheds = 3;
}
else
{
sheds = 2;
}
help = 2 * sheds;
C.
while (1)
{
printf("请输入数字:");
scanf_s("%d", &score);
if (score < 0)
{
break;
}
count++;
}
printf("count = %d\n", count);
0.
#include <stdio.h>
//本金 principal利息 interest
int main()
{
int count = 0,a;
double Money1 = 10000.0, Money2 = 10000.0;
a = 0.1 * Money1;
printf("%lf,%lf\n", Money1, Money2);
while (Money1 >= Money2)
{
Money1 += a;
Money2 *= 1.05;
count++;
printf("%d %.2lf %.2lf\n", count, Money1, Money2);
}
printf("过了%d年,小甲鱼%.2lf元,黑夜%.2lf元", count, Money1, Money2);
return 0;
}
1.
#include <stdio.h>
int main()
{
float Money = 4.0e+6;
int yers = 0;
while (Money > 0)
{
Money -= 5.0e+5;
Money *= 1.08;
yers += 1;
printf("还剩余%e元\n", Money);
}
printf("%d\n", yers);
return 0;
}
2.
#include <stdio.h>
int main()
{
float fz = 1.0, fm = 1.0;
double i = 0, result = 0;
while (1)
{
i = ((fz / fm) - (fz / (fm + 2)));
result += i;
printf("%lf\n", i);
fm += 4;
if (i<1.0e-12)
{
break;
}
}
printf("pi约等于%lf\n", result*4);
return 0;
}
3.
#include <stdio.h>
int main()
{
long long int nums = 2, mu1 = 0, mu2 = 0,a;
int time = 1,zt = 1;
while (time <= 24)
{
time++;
a = nums;
nums += mu2;/////////////////
mu2 = mu1;
mu1 = a * 2;
printf("%d %d %d\n", nums, mu1, mu2);
}
printf("共有%lld\n", nums+mu1+mu2);
return 0;
}
river-c
发表于 2024-8-21 22:55:12
{:5_109:}
刘叶舟
发表于 2024-8-22 10:11:01
是
lzy1343429224
发表于 2024-8-22 12:59:43
{:10_266:}
让等待充实
发表于 2024-8-24 10:44:35
伟大的xiao甲鱼
扬尘123
发表于 2024-8-25 22:26:40
{:5_109:}
rinlhx
发表于 2024-8-30 18:23:02
1
香风智智乃
发表于 2024-9-1 10:14:41
ll
Jiatianyu
发表于 2024-9-2 09:19:36
a
IZ009
发表于 2024-9-5 10:14:31
答案
Lxijun
发表于 2024-9-6 21:32:19
0,10次
1.10个
2.a
3,a=5, b=5 c=10
4.
萧忆风
发表于 2024-9-12 21:48:53
0.100
1.11
2.a,b,c
3.a = 14,b = 5,c = 9
4. z = x > -1 * x? x : -1 * x
5.
A:
if(size > 12)
{
cost *= 1.05;
flag = 2;
bill = cost * flag;
}
bill = cost * flag;
B:
if(idex > 14)
{
sheds = 3;
help = 2 * sheds;
}
shed = 2;
help = 2 * sheds;
C:
while(score >= 0)
{
scanf("%d",&sore);
count ++;
}
printf("count = %d\n",count);