单项选择题

有以下程序: #include <stdio.h> main() { int y=9; for(;y>0; y--) if(y%3==0) printf("%d", --y); } 程序的运行结果是______。

A.852
B.963
C.741
D.875421
<上一题 目录 下一题>
热门 试题

单项选择题
若有定义:float x=1.5; int a=1, b=3, c=2;则正确的switch语句是______。
A.switch(a+b)<br/>{ case 1: printf("*\n");<br/>case 2+1: printf("**\n");}
B.switch((int)x);<br/>{ case 1: printf("*n");<br/>case 2: printf("**\n");}
C.switch(x)<br/>{ case 1.0: printf("*\n");<br/>case 2.0: printf("**\n");}
D.switch(a+b)<br/>{ case 1: printf("*n");<br/>case c: printf("**\n");}
单项选择题
有以下程序:#include <stdio.h>main(){ int x=1, Y=0;if(!x)y++;else if(x==0)if(x)y+=2;else y+=3;printf( %d n , y);}程序运行后的输出结果是______。
A.3
B.2
C.1
D.0
相关试题
  • 以下叙述中正确的是______。
  • 有以下程序:#include <stdio.h>main...
  • 以下叙述中错误的是______。
  • 有以下程序:#include <stdio.h>#inc...
  • 有以下程序:#include <stdio.h>struc...