以下程序的运行结果是____。[br][/br]#include[br][/br]#include[br][/br]intmain()[br][/br]{[br][/br]chars[20]="abcd";[br][/br]char*sp=s;[br][/br]sp++;[br][/br]puts(strcat(sp,"ABCD"));[br][/br]return0;[br][/br]}
举一反三
- Which of the following program is right? ( ) A: #include<br/>int main();<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>} B: #include<br/>int main()<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>} C: include <br/>void main()<br/>{ /*programming*/ <br/>printf("programming!\n");<br/>return 0;<br/>} D: #include<br/>int mian()<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>}
- 有以下程序[br][/br]#include <stdio.h>[br][/br]main( )[br][/br]{ unsigned char a=8,c;[br][/br]c=a>>3:[br][/br]printf("%d\n",c);[br][/br]}[br][/br]程序运行后的输出结果是( )。 A: 32 B: 16 C: 1 D: 0
- 下面程序的运行结果是____。[br][/br]#include[br][/br]intmain()[br][/br]{[br][/br]inta[][3]={{1,2,3},{4,5,0}},(*pa)[3],i;[br][/br]pa=a;[br][/br]for(i=0;i[3;i++)<br]if(i[2)pa[1][i]=pa[1][i]–1;<br]elsepa[1][i]=1;[br][/br]printf("%d\n",a[0][1]+a[1][1]+a[1][2]);[br][/br]return0;[br][/br]}[/i][/i][/i]
- 执行以下指令后,(SP) =____,(A)=____,(B)=____。[br][/br]MOV SP,#70H[br][/br]MOV A,#60H[br][/br]MOV B,#0F8H[br][/br]PUSH ACC [br][/br]PUSH B[br][/br]POP ACC[br][/br]POP B
- 下面程序的输出结果是( )。[br][/br]#include [stdio.h][br][/br]enum DAY[br][/br]{[br][/br] MON=1, TUE, WED, THU, FRI, SAT, SUN[br][/br]};[br][/br]int main()[br][/br]{[br][/br] enum DAY day;[br][/br] day = TUE;[br][/br] printf("%d",day);[br][/br] return 0;[br][/br]} A: TUE B: 0 C: 1 D: 2