有以下程序main(){ char *p[]={"3697","2584"};int i,j; long num=0;for(i=0;i2;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)num=10*num+p[i][j]-'0';
j+=2;
}
}
printf(" % d\n",num);
}
程序执行后的输出结果是
A)35
B)37
C)39
D)3975
相关考题:
有以下程序:main(){ char *p[]={"3697","2584"}; int i,j; long num=0; for(i=0;i2;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;i2;i++) {j=0; while(p[i][j]!=\0) {if((p[i][j]-t\0)%2)num=10*num+p[j][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
有以下程序:include main( ) char * p[ ] = {"3697" ,"2548" }; int i,j;long num =0 有以下程序: #include <stdio.h> 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)num=10*num+p[i][j]-'0'; j+=2; } } printf("%d\n",num); } 程序执行后的输出结果是( )。A.35B.37C.39D.3975
以下程序输出正确的是_______ amovep(int *p,int (*a)[3],int n) { int i,j; for(i=0;i<n;i++) for(j=0;j<n;j++){ *p=a[i][j];p++;} } main() {int *p,a[3][3]={{1,3,5}, {2,4,6}}; p=(int*)mallox(100) amovep)p,a,3); printf("%d%d\n",p[2],p[5]);free(p) }A.56B.25C.34D.程序错误
有下列程序: main { char*p[]={"3697","2584"}; int i,j;long num=0; for(i=0;i2:i++) { j=0; while(p[i][j]!=\0) { if((p[i][j]-\0 )%2)num=1O*num+p [j][j]-0; j+=2; } } printf("%d\n",num); } 程序执行后的输m结果是( )。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[il[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;i2:i++){ j=0;while(p[i][j]!=\0){ if((p[i][j]-\0 )%2)num=1O*num+p[j][j]-0;j+=2;}}printf(%d\n,num);}程序执行后的输m结果是( )。A.35B.37C.39D.3975