填空题
下面程序的运行结果是______。
##include<stdio.h>
main()
int a,s,n,m;
a=2;s=0;n=1;m=1;
while(m<=4)n=n*a;s=s+n;++m;
printf("s=%d",s);
【参考答案】
s=30
点击查看答案&解析
<上一题
目录
下一题>
热门
试题
填空题
以下程序的运行结果是______。 main() int a=1,b=2,c; if(a>b)c=1; else if(a==b)c=0; else c=-1; printf( %d n ,c);
点击查看答案
填空题
若有定义:int x=1,y=2;float a=3.7,b=2.1;则(x+y)%2+(int)a (int)b表达式的值为______。
点击查看答案&解析
相关试题
下面程序的运行结果是______。 #de...
有以下程序 #include<stdio.h> typed...
下面程序的运行结果是______。 #in...
下列函数从字符数组s[]中删除和c一样的字...
以下程序的功能是:对输入的一行字符中的数...