下列程序的输出结果是()。includemain(){ struct st{ int y, x,z;};union{ long i;int 下列程序的输出结果是( )。#include<stdio.h>main(){ struct st { int y, x,z; }; union { long i; int j; char k; }un; printf("%d,%d\n",sizeof(struct st),sizeof(un));}A.6,2B.6,4C.8,4D.8,6

下列程序的输出结果是()。includemain(){ struct st{ int y, x,z;};union{ long i;int

下列程序的输出结果是( )。#include<stdio.h>main(){ struct st { int y, x,z; }; union { long i; int j; char k; }un; printf("%d,%d\n",sizeof(struct st),sizeof(un));}

A.6,2

B.6,4

C.8,4

D.8,6


相关考题:

下列程序的输出结果是非曲直【 】。includeclass base{ int x, y;public: base(int i, 下列程序的输出结果是非曲直【 】。include<iostream, h>class base{int x, y;public:base(int i, int j){x=i; y=j;}virtual int add(){return x+ y;}};class three: public base{int z;public:three(int i, int j, int k) :base(i, j){z=k; }int add() { return (base:: add()+z); }};void main(){three * q=new three(lO,20,30);cout<<q->add()<<end1;}

下列程序的输出结果是( )。 #include "stdio.h" main() { struct st { int y,x,z;}; union {long i;int j; char k;} un; printf("%d,%d\n",sizeo(struct st),sizeof(un)); }A.6,2B.6,4C.8,4D.8,6

下列程序的输出结果是()。 include VOid p(int *x) {printf("%d",++*x); } void main() 下列程序的输出结果是( )。#include<stdio.h>VOid p(int *x){ printf("%d",++*x);}void main(){ int y=3;p(y);}A.3B.4C.2D.5

下列程序的输出结果是()。includevoid p(int *x){printf("%d",++*x);}void main(){int 下列程序的输出结果是( )。 #include<stdio.h> void p(int *x) { printf("%d",++*x); } void main() { int y=3; p(y); }A.3B.4C.2D.5

下列程序的输出结果是( )。 #includestdio.h main { struct st { int y,x,z; }; union { long i; int j; char k; }un; printf("%d,%d\n",sizeof(struct st),sizeof(un)) }A.6,2B.6,4C.8,4D.8,6

有如下程序:includeint func(int a,int b){return(a+b):}main(){int x=2,y=5,z=8,r; r 有如下程序: #include <stdio.h> int func(int a,int b) { return(a+b):} main() { int x=2,y=5,z=8,r; r=func(func(x,y),z); printf("%d\n",r); } 该程序的输出结果是( )。A.12B.13C.14D.15

下列程序的输出结果是()。includemain(){struct st{int y,x,z;};union{long i; int j; 下列程序的输出结果是( )。 #include<stdio.h> main() { struct st { int y,x,z; }; union { long i; int j; char k; }un; printf("%d,%d\n",sizeof(struct st),sizeof(un)); }A.6,2B.6,4C.8,4D.8,6

下列程序的输出结果是()。 include main() {stmct st {int y,x,z; }; union {long i; i 下列程序的输出结果是( )。#include<stdio.h>main(){ stmct st{ int y,x,z;};union{ long i;int j;char k;}un;printf("%d,%d\n",sizeof(stmct st),sizeof(un));}A.6,2B.6,4C.8,4D.8,6

下列程序的输出结果是( )。 include main() { struct st { int y,x,z; }; union {long 下列程序的输出结果是( )。 #include <stdio.h> main() { struct st { int y,x,z; }; union { long i; int j; char k; } un; printf("%d,%d\n",sizeof(struct st),sizeof(un)); }A.6, 2B.6, 4C.8, 4D.8, 6

下列程序的输出结果是()。 include voidp(int*x) {printf("%d",++*x); } voidmain() {i 下列程序的输出结果是( )。#include<stdio.h>voidp(int*x){printf("%d",++*x);}voidmain(){int y=3;p(y);}A.3B.4C.2D.5

以下程序的输出结果是【】。 include main() {struct stru {int a; float b; char d[4]; } 以下程序的输出结果是【 】。include<stdio.h>main(){ struct stru{ int a;float b;char d[4];};printf("%d\n",sizeof(struct stru));}

有以下程序 include struct st { int x,y;} data[2]={1,10,2,20}; main( 有以下程序 #include <stdio.h> struct st { int x,y;} data[2]={1,10,2,20}; main() { struct st *p=data; printf("%d,",p->y); printf("%d\n",(++p)->x); } 程序的运行结果是______。A.10,1B.20,1C.10,2D.20,2

有下列程序: include int f(int x) { int y; if(x=0‖x==1)r 有下列程序: #include <stdio.h> int f(int x) { int y; if(x=0‖x==1)return(3); y=x*x-f(x-2); return y; } main() { int z; z=f(3);printf("%d\n",z); 程序的运行结果是( )。A.0B.9C.6D.8

以下程序输出结果是 ______。includevoid fun(int x,int y,int z){z=x+y;}void main 以下程序输出结果是 ______。 #include<iostream.h> void fun(int x,int y,int z){z=x+y;} void main() { int a=10; fun (2,2,a); cout<<a; }A.0B.4C.10D.无定值

有如下程序段#include "stdio.h"typedef union{ long x[2]; int y[4]; char z[8];}atx;typedef struct aa { long x[2]; int y[4]; char z[8];} stx;main(){ printf("union=%d,struct aa=%d\n",sizeof(atx),sizeof(stx));}则程序执行后输出的结果是A.union=8,struct aa=8 B.union=8,struct aa=24C.union=24,struct aa=8 D.union=24,struct aa=24

下面程序的输出结果是( )。 #include "stdio.h" fun (x int x { int y=0; static int z=5; z=x++,y++; return(Z); } main() { int a=4,i,j; for(i=0;i<2;i++) j=fun(a++); printf("%d",j); }A.0B.3C.4D.5

以下程序执行后的输出结果是include using namespace std;void try(int,int,int,int) 以下程序执行后的输出结果是 #include <iostream> using namespace std; void try(int,int,int,int); int main () { int x,y,z,r; x =1 ; y = 2; try(x,y,z,r); cout<<r<<endl; return 0; } void try(int x,int y,int z,int r) { z = x+y; x = x*x; y = y*y; r = z+x+y; }A.18B.9C.10D.不确定

以下程序的输出结果是includemain(){ union un{ int i;long k;char c;};struct byte{i 以下程序的输出结果是 #include<stdio.h> main() { union un{ int i; long k; char c;}; struct byte{ int a; long b; union un c;}r; printf("%d\n",sizeof(r));}A.10B.13C.7D.8

下列程序的执行结果是______。include union {int i;char c[2]; }; void main() {union 下列程序的执行结果是______。 #include<stdio.h> union { int i; char c[2]; }; void main() { union un x; x.c[0]=10; x.c[1]=1; printf("\n%d",x.i); }A.266B.11C.265D.138

下列程序的输出结果是______。include main(){union {int k;char i[2]; }*S,a; s= 下列程序的输出结果是______。#include <stdio.h>main(){ union { int k; char i[2]; } *S,a; s=a; s->i[0]=0x39; s->i[1]=0x38; printf("%x\n",s->k);}A.3839B.3938C.380039D.390038

以下程序的输出结果是includestruct st{ int x;int *y;}*p;int dt[4]={10,20,30,40};s 以下程序的输出结果是 #include<stdio.h> struct st { int x;int *y;}*p; int dt[4]={10,20,30,40}; struct st aa[4]={50,dt[0],60,dt[0],60,dt[0],60,dt[0],}; main() { p=aa; printf("%d\n",++(p->x));}A.10B.11C.51D.60

以下程序的输出结果是() includemain(){ union un{int i; long k; char c;};struct by 以下程序的输出结果是( ) # include<stdio.h> main() { union un{int i; long k; char c; }; struct byte{ int a; long b; union un c; } r; printf("%d\n",sizeof(r)); }A.10B.13C.7D.8

请读程序:includefunc(int a, int b){int c; c=a+b; return c;}main(){int x=6,y=7,z= 请读程序: #include <stdio.h> func(int a, int b) { int c; c=a+b; return c; } main() { int x=6,y=7,z=8,r; r=func((x--,y++,x+y),z--); printf("%d\n",r); 上面程序的输出结果是( )。A.11B.20C.21D.31

有以下程序:includefun(int x,int y,int z){z=x*y;}main(){int a=4,b=2,c=6; fun(a,b, 有以下程序: #include <stdio.h> fun(int x,int y,int z) { z=x*y;} main() { int a=4,b=2,c=6; fun(a,b,c); printf("%d",c); } 程序运行后的输出结果是( )。A.16B.6C.8D.12

下列程序的执行结果是______。include union un{ int i;char c[2];};void main(){union 下列程序的执行结果是______。 #include <stdio.h> union un { int i; char c[2]; }; void main() { union un x; x.c[0]=10; x.c[1]=1; printf("\n%d",x.i) }A.266B.11C.265D.138

下列程序运行后的输出结果是()。 include void fun(int,int,int*); void main() { i 下列程序运行后的输出结果是( )。 #include<iostream.h> void fun(int,int,int*); void main() { int x,y,z; fun(5,6,x); fun(7,x,y); fun(x,y,z); cout<<x<<","<<y<<","<<z<<end1; } void fun(int a,int b,int *c) { b+=a; *c=b-a; }A.5, 5, 5B.6, 6, 6C.5, 6, 7D.7, 7, 7

下列程序的输出结果是______。 include main() { double d=3.2;int x,y; x=1.2;y=(x+3. 下列程序的输出结果是______。 #include<stdio.h> main() { double d=3.2;int x,y; x=1.2;y=(x+3.8)/5.0; printf("%d\n",d*y); }A.3B.3.2C.0D.3.07

下列程序的输出结果是______。 include class base { int x,y; public: base(int i,i 下列程序的输出结果是______。include<iostream.h>class base{int x,y;public:base(int i,int j){x=i;y=j;}virtual int add( ){return x+y;}};class three:public base{int z;public:three(int i,int j,int k):base(i,j){z=k;)int add( ){return(base::add( )+z);}};void main( ){three*q=new three(10,20,30);cout<<q->add( )<<endl;}