下面程序的输出结果是【 】。 char b[]="ABCD"; main() { char *p=b; for(;*p;p
下面程序的输出结果是【 】。 char b[]="ABCD"; main() { char *p=b; for(;*p;p++) printf("%s",p); printf("\n"); }
下面程序的输出结果是【 】。 char b[]="ABCD"; main() { char *p=b; for(;*p;p++) printf("%s",p); printf("\n"); }
第1题
下面程序的输出结果是______。
#include"stdio.h"
main()
(cbar b[]="ABCD";
char*chp;
for(chp=b;*chp;chp+=2)
printf("%s\t",chp);
printf("\n");
}
第2题
下面程序的输出结果是【 】。 char b[]="ABCD"; main() { char b[30]; strcpy(&b[0],"GH"); strcpy(&b[1],"GH”); strcpy(&b[2],"GH"); printf("%s\n",B) ; }
第3题
下面程序的输出结果是【 】。 include<stdio.h> main() { static char a[]="language" ,b[]="program"; char*ptrl=a,*ptr2=b; int k; for(k=0;k<7;k++) if(*(ptrl+k)==*(ptr2+k)) printf("%c",*(ptrl+k));}
第4题
下面程序的输出结果是【 】。 include <stdio.h> main() { staic char b[]="Goodbye"; char * chp = &b [7]; while(- - chp>=&b[0])putchar (* chp); printf("\n"); }
第5题
下面程序的输出结果是【 】。 main() { int i=3,j=2; char * a="DCBA"; printf("%c%c\n",a[i],a[j]) }
第6题
下面程序的输出结果是【 】。
char b[]="ABCD";
main()
{
char b[30];
strcpy(&b[0],"GH");
strcpy(&b[1],"GH");
strcpy(&b[2],"GH");
printf("%s\n",b);
}
第7题
执行下面程序后,输出结果是【 】。 main() { char s[12]="very good!"; printf("%d",strlen(s)); }
第8题
阅读下面程序段,则执行后输出的结果是()。 include“stdio.h” void main() { char fun(char,int); char a;‘A’; int b=13; a=fun(a,b); putchar(a); ) char fun(char a,int b) { char k; k=a+b; return k; )
A.A
B.M
C.N
D.L
第9题
下面程序的输出结果是()。 include <stdi0.h> include<string.h> main() {char*pl=“abc”,str[50]=“xyz”; strcpy(Str+2,p1); printf(“%S\n”,Str); }
A.xyzabcABC
B.zabcABC
C.xyabc
D.yzabcABC