若有下面的说明和定义: struct test { int m1; char m2; float m3; union uu {char u1[5]; int u2[2];}ua; }myaa; 则sizeof(stmct test)的值是( )。
A.12
B.16
C.14
D.9
第1题:
已知有变量datal定义如下: union data { int i; char ch; float f; }datal; 则变量datal所占的内存存储空间可表示为(57)。
A.sizeof(int)
B.sizeof(char)
C.sizeof(float)
D.SiZCOf(mt)+sizeof(char)+sizeof(float)
第2题:
已知: union { int i; char c; float a; }st;则sizeof(st)的值是______。
A.4
B.5
C.6
D.7
第3题:
若有下面说明和定义:struct test{ int m1;char m2;float m3;union uu(char u1[5];int u2[2];)ua;}myaa; 则sizeof(struct test)的值是( )。A)20 B)16C)14 D)9
第4题:
若有如下说明和定义struct test{ int ml; char m2; float m3; union uu {char ul[5]; int u2[2];} ua;} myaa;则sizeof(struct test)的值是A.12 B.16 C.14 D.9
第5题:
若有下面的说明和定义
struct test
{ int ml; char m2; float m3;
union uu {char ul[5]; int u2[2];} ua;
} myaa;
则sizeof(struct test )的值是
A.12
B.16
C.14
D.9
第6题:
若有下列说明和语句,已知int型数据占2个字节,则下列语句的输出结果是( )。
stmct st
{ char a[15];
int b;
double c;
};
printf("%d",sizeof(struct st));
A.15
B.8
C.25
D.2
第7题:
● 已知有变量 data1 定义如下:
union data
{ int i;
char ch;
float f;
} data1;
则变量 data1 所占的内存存储空间可表示为 (57) 。
(57)
A. sizeof(int)
B. sizeof(char)
C. sizeof(float)
D. sizeof(int)+sizeof(char)+sizeof(float)
第8题:
已知程序中已经定义了函数test,其原型是int test(int,int,int);,则下列重载形式中正确的是
A.char test (int,int,int);
B.double test(int,int,double);
C.int test(int,int,int=O);
D.float test(int,int,float=3.5F);
第9题:
设有以下说明和定义:
typedef union {long i; int k[5]; char c;} DATE;
struct data { int cat; DATE cow; double dog;} too;
DATE max;
则语句 printf("%d",sizeof(struct date)+sizeof(max));的执行结果是:___52____
第10题:
若有下面的说明和定义,则sizeof(struct aa) 的值是 struct aa { int rl;double r2;float r3; union uu {char ul [5];long u2[2]}ua; }mya;
A.30
B.29
C.24
D.22