更多“以下程序段运行后的输出结果是 int a=2,b=1,c=2; if(a) { if(b<0) c=0; } else c++; printf("%dn",c);”相关的问题
第1题
以下程序段运行后的输出结果是: char a=’a’ , b; printf("%c,", ++a); printf(“%cn” ,b=a++ );
点击查看答案
第2题
假定所有变量均已正确说明,以下程序段运行后的输出结果是 。 int k; k=-3; if(k<=0) printf(“####”); else printf(“&&&&”);
A.####
B.&&&&
C.####&&&&
D.有语法错误,无输出结果
点击查看答案
第3题
以下程序段输出的结果是()。 int a=97; printf("%cn",a);
点击查看答案
第4题
以下程序段的输出结果是 ___。 main() { int a=177; printf("%on",a); }
点击查看答案
第5题
假定所有变量均已正确说明,以下程序段运行后的输出结果是()。 int k=5; while(--k) printf("%d", k-=3); printf("n");
点击查看答案
第6题
假定所有变量均已正确说明,以下程序段运行后的输出结果是 。 int a=3,b=5,c=7; if(a>b) a=b; c=a; if(c!=a) c=b; printf("%d,%d,%dn",a,b,c);
A.程序段有语法错
B.3,5,3
C.3,5,5
D.3,5,7
点击查看答案
第7题
以下程序段运行后的输出结果是()。 int x=1,y=0; if(!x) y++; else if(x==0) if (x) y+=2; else y+=3; printf("%dn",y);
点击查看答案
第8题
假定所有变量均已正确说明,以下程序段运行后的输出结果是 。 int a=1,b=3,c=5; if(c=a+b) printf("yesn"); else printf("non");
点击查看答案
第9题
以下程序段的输出结果是 ___。 main() { int a=0; a+=(a=8); printf("%dn",a); }
点击查看答案
第10题
关于以下程序段说法正确的是()。 char a[3],b[]="China"; a=b; printf("%s",a);
A.运行后将输出China
B.运行后将输出Ch
C.运行后将输出Chi
D.编译出错
点击查看答案