有以下程序 main( ) { char str[ ]="xyz",*ps=str; while(*ps) ps++; for(ps--;ps-str>=0;ps--) puts(ps);} 执行后输出结果是
A.yz xyz
B.z yz
C.z yz xyz
D.x xy xyz
第1题:
有以下程序main(){ char str[]="xyz",*ps=str; while(*ps) ps++; for(ps--; ps-str>=0; ps--) puts(ps);} 程序的运行结果是A.yz B.z C.z D.x xyz yz yz xy xyz xyz
第2题:
下列程序中,正确的为______。
A.main() { int *pb=&b; float 1>=15.25; print f("%d\n" ,*pb); }
B.amin() { int a,*pa; a=10; *pa=a; prinffC%d",*pa); }
C.main() { char s[20]; char *ps=&s; scanf("%s",*p); printf("%s",*p); }
D.main() { char str[10]; int *ps=str[0]; str="abcdefg"; printf("%s",*p); }
第3题:
有以下程序 main ( ) { char str[] ="xyz", *ps=str; while (*ps) ps++: for (ps-- ;ps-str>=0 ;ps--) puts(ps); } 执行后输出结果是
A.yz xyz
B.z yz
C.z yz xyz
D.x xy xyz
第4题:
以下程序 #include<stdio.h> #include<string.h> main() { char*pl="abc",*p2="ABC",str[50]="xyz"; strcpy(str+2,strcat(p1,p2)); printf("%s\n",str); } 的输出是________。
A.xyzabcABC
B.zabcABC
C.yzabcABC
D.xyabcABC
第5题:
有以下程序 main() { char atr[]="xyz",*ps=str; while(*ps)ps++; for(ps--;ps-str>=0;ps--) puts(ps); } 执行后输出结果是
A.yz xyz
B.x yz
C.z yz xyz
D.x xy xyz