网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)

【填空题】下列程序的输出结果是 。 #define SQR(t) t*t void main() {int a = 1, b=2, s; s = SQR(a * b); printf("%d", s); }


参考答案和解析
12
更多 “【填空题】下列程序的输出结果是 。 #define SQR(t) t*t void main() {int a = 1, b=2, s; s = SQR(a * b); printf("%d", s); }” 相关考题
考题 下面程序运行后的输出结果是( )。struct abc{int a,b,c;}main(){struct abc s[2]={{1,2,3},{4,5,6}};int t;t=s[0].a+s[1].b;printf("%d\n",t);}A.5 B.6 C.7 D.8

考题 有以下程序void ss(char *s,char t){ while(*s){ if(*s==t)*s=t-′a′+′A′;s++; } }main(){ char str1[100]="abcddfefdbd",c=′d′;ss(str1,c); printf("%s\n",str1);}程序运行后的输出结果是A.ABCDDEFEDBDB.abcDDfefDbDC.abcAAfefAbAD.Abcddfefdbd

考题 有下列程序:main{int i,s=0,t[]={1,2,3,4,5,6,7,8,9};for(i=0;i9;i+=2)s+=*(t+i);printf(9;i+=2)s+=*(t+i);printf(%d\n,s);}程序执行后的输出结果是( )。A.A.45B.20C.25D.36

考题 下列程序的输出结果是( ) struct abc { int a,b,c;}; main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t); }A.3B.4C.5D.6

考题 下面程序的运行结果是( )。include define SlZE 12 main() {char s[SIZE];int i;for(i=0 下面程序的运行结果是( )。include<stdio.h>define SlZE 12main(){char s[SIZE];int i;for(i=0;i<SIZE;i++) s[i]='A'+i+32;sub(s,5,SIZE-1);for(i=0;i<SIZE;i++)printf("%c",s[i]);printf("\n");}sub(char *a,int t1,int t2){ char ch;while(t1<t2){ ch=*(a+t1);*(a+t1)=*(a+t2);*(a+t2)=ch;t1++;t2--;}}

考题 下列程序的输出结果是()。includestruct abc{int a, b, c, s;};main(){struct abc s[2] 下列程序的输出结果是( )。 #include <stdio.h> struct abc { int a, b, c, s;}; main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t); }A.5B.6C.7D.8

考题 以下程序的输出结果是 ( ) # define SQR (X) X*X main( ) { int a=16,k=2,m=1; a/=SQR(k+m)/SQR(k+m); printf("%d\n",a); }A.16B.2C.9D.1

考题 执行下列程序后,输出的结果是()。 includedefine S(X) X*Xvoid main(){int a=9,k=3,m= 执行下列程序后,输出的结果是( )。 #include<stdio.h> #define S(X) X*X void main() { int a=9,k=3,m=2; a/=S(k+m)/S(k+m); printf("%d",a); }A.1B.4C.9D.0

考题 下列程序的运行结果是()。includevoid fun(int*s,int*p){ static int t=3;*p=s[t];t--; 下列程序的运行结果是( )。#include<stdio.h>void fun(int*s,int*p){ static int t=3; *p=s[t]; t--;}void main(){ int a[]={2,3,4,5),k; int x; for(k=0;k<4;k++) { fun(a,x); printf("%d,",x); }}A.5,4,3,2B.2,3,4,5,C.2,2,2,2,D.5,5,5,5,

考题 下列程序的运行结果是()。 include voidfun(int*s,int*p) {static int t=3; *p=s[t]; t 下列程序的运行结果是( )。#include<stdio.h>voidfun(int*s,int*p){ static int t=3;*p=s[t];t--;}void main(){ int a[]={2,3,4,5},k;int x;for(k=0;k<4;k++){ fun(a,x);printf("%d,",x);}}A.5,4,3,2B.2,3,4,5,C.2,2,2,2,D.5,5,5,5,

考题 以下程序的输出结果是【 】。include int fun(int x) {static int t=0; return(t+=x); } 以下程序的输出结果是【 】。include <stdio.h>int fun(int x){ static int t=0;return(t+=x);}main()int s,i;for(i=1 ;i<=5;i++) s=fun(i);printf("%d\n",s);

考题 以下程序的输出结果是 ______。 #define SQR(X) X * X main() { int a=16,k=2,m=1; a/=SQR(k/m)/SQR(k+m); printf("%d\n",A) ; }A.16B.2C.9D.1

考题 下列程序的运行结果是()。includevoid fun (int*s,int*p){ static int t=3; *p=s [t]; 下列程序的运行结果是( )。 #include<stdio.h> void fun (int*s,int*p) { static int t=3; *p=s [t]; t--; } void main() int a[]={2, 3, 4, 5},k; int x; for(k=0; k<4; k++) { fun (a, x); printf("%d,", x); }A.5,4,3,2B.2,3,4,5,C.2,2,2,2,D.5,5,5,5,

考题 有以下程序 void ss(char *s,char t) { while { *s) if (*s==t) *s-t-'a' +'A'; S++; main () { char strl [100] =" abcddfefdbd" , c= 'd'; ss(str1,c); printf ("%s\n" ,str1); } 程序运行后的输出结果是A.ABCDDEFEDBDB.abcDDfefDbDC.abcAAfefAbAD.Abcddfefdbd

考题 以下程序的输出结果是 ______。includedefine SQR(x)x*xmain((){ int a,k=3;a=++SQR(K 以下程序的输出结果是 ______。#include<stdio.h>#define SQR(x)x*xmain((){ int a,k=3; a=++SQR(K+1); printf("%d\n",A) ;}A.8B.9C.17D.20

考题 有如下程序段struct abc{ int a, b, c, s;};main(){ struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t);}程序运行后输出的结果是A.5 B.6 C.7 D.8

考题 以下程序的输出结果是_______。includedefine SQR(x)x*xmain(){int a;k=3; a=++SQR(k+ 以下程序的输出结果是_______。 #include<stdio.h> #define SQR(x)x*x main() { int a;k=3; a=++SQR(k+1); printf("%d\n",a) ; }A.8B.9C.17D.20

考题 下面程序的运行结果是#include #define SIZE 12sub(char *a,int t1,int t2) { char ch; while(t1t2) { ch=*(a+t1); *(a+t1)=*(a+t2); *(a+t2)=ch; t1++;t2--; }} main() { char s[SIZE]={’A’,’B’,’C’,’D’,’E’,’F’,’G’,’H’,’I’,’J’,’K’,’L’}; int i; sub(s,7,SIZE-1); for(i=0;iSIZE;i++) printf("%c ",s[i]); printf("\n");}

考题 有以下程序:includeint f(int t[],int n);main(){int a[4]={1,2,3,4},s;s=f(a,2);prin 有以下程序: #include<stdio.h> int f(int t[],int n); main() {int a[4]={1,2,3,4},s; s=f(a,2);printf("%d\n",s); } int f(int t[],int n) {if((n>0)(n<5))return t[n+1]+f(t,n-1); else return 0; } 程序运行后的输出结果是( )。A.4B.7C.10D.61

考题 有以下程序 void ss(char*s,char t) { while(*s) { if(*s==t)*s=t-'a'+'A'; s++; }} main() { char strl[100]="abcddfefdbd",c='d'; ss(str1,c);printf("%s\n",strl);} 程序运行后的输出结果是A.ABCDDEFEDBDB.abcDDfefDbDC.abcAAfefAbAD.Abcddfefdbd

考题 下面程序运行后的输出结果是______。 struct abc { int a,b,c; } main() { struct abc s [2]={{1,2,3},{4,5,6}}; int t=-s[0].a+s[1].b; printf("%d\n",t); }A.5B.6C.7D.8

考题 以下程序的输出结果是______。includedefine SQR(x)x*xmain(){int a,k=3; a=++SQR(k+1 以下程序的输出结果是______。 #include<stdio.h> #define SQR(x)x*x main() { int a,k=3; a=++SQR(k+1); printf("%d\n",a); }A.8B.9C.17D.20

考题 有以下程序: #includedstdi0.h #define f(x)X*x*x main( ) {int a=3,S,t; s=f(a+1);t=f((a+1)); printf("%d,%d\n",S,t); } 程序运行后的输出结果是( )。A.10,64B.10,10C.64,10D.64,64

考题 下列程序的输出结果是______。 #define SQR(X) X*X main ( ) { int a=16, k=2, m=1; a/=SQR (k+m)/SQR (k+m); printf ("d\n", a); }A.16B.2C.9D.1

考题 有以下程序:include void swap(char * x,ehar * y){ char t;t= *x; *x: *y; *y=t;main 有以下程序:#include <stdio.h>void swap(char * x,ehar * y){ char t; t= *x; *x: *y; *y=t;main ( ){ char *s1 ="abc", * s2 ="123"; swap(s1 ,s2); printf("%s,%s \n" ,s1 ,s2);}程序执行后的输出结果是( )。A.123,abeB.abe,123C.1bc,a23D.321,cba

考题 下面程序的输出结果是( )。 #define SQR(X) 2*X+1 main() { int a,b,C; a=3;b=2;C=1; a* =SQR(b+c)/SQR(b+c); printf("%d",a); }A.3B.18C.21D.24

考题 有以下程序  void swap(Char *x,Char *y)      {Char t;     t=*x;*x=*y;*y=t;      }   main( )  {Char *s1=”abc”,*s2=”123”;      swap(sl,s2);  printf(”%s,%s/n”,s1,s2);     }  程序执行后的输出结果是()A、abe,123B、123,abcC、321,cbaD、1bc,a23

考题 单选题有以下程序:#include #include void fun(int*p1,int*s){ int *t; t=(int*)malloc(2*sizeof(int)); *t=*p1+*p1++; *(t+1)=*p1+*p1; s=t;}main(){ int a[2]={1,2}, b[2]={0}; fun(a,b); printf(%d,%d,b[0],b[1]);}程序运行后的输出结果是(  )。A 2,6B 0,0C 2,4D 1,2