A.2
B.3
C.4
D.5
[单选题]有以下程序 main() { char*p[10]={"abc",aabdfg","dedbe","abbd","cd"}; printf("%d/n",stxlen (p[4])); } 执行后输出结果是A.2B.3C.4D.5
[单选题]有如下程序 main() { char s[][5]={"abc","de","fgh"}; printf("%c",s[2][6]); } 其输出为______。A.不确定B.编译错误C.gD.输出null字符
[单选题]以下程序includeincludemain(){char*p1="abc",*p2="ABC",str[50]="xyz", s以下程序 #include<stdio.h> #include<string.h> main() { char*p1="abc",*p2="ABC",str[50]="xyz", strcpy(str+2,strcat(p1,p2)); printf("%s/n",str); } 的输出是______。A.xyzabcABCB.zabcAB
[单选题]有以下程序inc1udemain(){char*s={"ABC"}; do {printf("%d",*s%10);s£«£«; }while(*s);有以下程序 #inc1ude<stdio.h> main() { char*s={"ABC"}; do { printf("%d",*s%10); s++; } while(*s); } 注意字母A的ASCII码值为65。程序运行后的输出结果是______。A.5670B.656667C.567D.ABC
[单选题]有以下程序: main() {char*p[]={"3697","2584"}; int i,j;long num=0; for(i=0;i<2;i++) {j=0; while(p[i][j]!='/0') {if((p[i][j]-'0')%2)num=10*num+p[i][j]-'0'; j+=2; } } printf("%d/n",num); } 程序执行后的输出结果是( )。A.35B.37C.39D.3975
[单选题]有以下程序 main() { char *p[]={"3697","2548"}; int i,j; long num=0; for(i=0;i<2;i++) {j=0; while(p[i][j]!='/0') { if((p[i][j]-'0')%2) num=10*num+p[i][j]-'0'; j+=2; } } printf("%d/n",num); } 程序执行后的输出结果上______。A.35B.37C.39D.3975
[单选题]有以下程序:main(){ char *p[]={"3697","2584"}; int i,j; long num=0; for(i=0;i<2;i++) {j=0;while(p[i][j]!=’/0’){ if((p[i][j]-’0’)%2= =0)num=10*num+p[i][j]-’0’; j+=2;} } printf("%d/n",num);}程序执行后的输出结果是( )。A.35 B.37C.39 D.28
[单选题]有以下程序:main(){ char *p[]={"3697","2584"}; int i, j; long num=0; for(i=0;i<2;i++) {j=0; while(p[i][j]!='/0') { if((p[il[j] -'0')%2) num=10*num+ p[i][j] -'0'; j+=2; } printf("%d/n", num);}程序执行后的输出结果是( )。A.35B.37C.39D.3975
[单选题]有以下程序: main() { char str[][10]={"China","Beijing"),*P=str; printf("%s/n",p+10); } 程序运行后的输出结果是 ______。A.ChinaB.BeijingC.ngD.ing
[单选题]有以下程序: main() { char a[]="abcdefg",b[10]="abedefg";printf("%d%d/n",sizeof(A) ,sizeof(B) ); } 执行后输出结果是( )。A.7 7B.8 8C.8 10D.10 10