写出下列程序的运行结果______ 。#include void main() { int x=1,y=2,z=3; if(x--) y++,z++; else y--; z--; printf(“%d, %d, %d\n”,x,y,z); }
查看答案
写出下列程序的运行结果______ 。 # include < stdio.h> void main() { int a=10,b=20,c=30,d; d=++a<=10||b-->=20||c++; printf(“%d,%d,%d,%d\n”,a,b,c,d); }
已有定义“int n=8;”,执行 switch(n--) { case 8: n--; case 7: n--;break; default: n--; }语句后,n的值是______ 。
已有定义“int a,b,c;”,且a=b=c=1,执行 if(a++||++b) c++;语句后,b的值是______ 。
执行以下程序段: int s=15; switch(s/4) { case 1: printf(“1”); case 2: printf(“2”); case 3: printf(“3”); default: printf(“0”); }后,输出结果是()
A. 3
B. 20
C. 30
D. 10