|
|
发表于 2018-10-28 11:42:59
|
显示全部楼层
0.long long int类型
1.字符型变量
2.是
3.4位
4.布尔类型?
5.A B F
6.int
7.程序只会按既定套路运行 大概这个意思吧
0.
#include <stdio.h>
#include <math.h>
int main()
{
int result;
result = pow(1,2) + pow(2,3) + pow(3,4) + pow(4,5) + pow(5,6);
printf("result = %d \n", result);
getchar();
return 0;
}
1.
#include <stdio.h>
#include <math.h>
int main()
{
int i = 0;
int total;
int weight;
for(i=0; i<64; i++)
{
total += pow(2,i);
}
weight = total / 25000;
printf("íõ¸Ã¸ø′ó3¼%dá£Âó×ó£¡\n", total);
printf("èç1ûÿ25000á£Âó×óÖØ1kg£¬ÄÇÃ′éáo±íõó|¸Ã¸øóè′ïòà¶û%d1«½ïÂó×ó¡£", weight);
getchar();
return 0;
}
并没输出正确 不知道原因 |
|