A-A+

以下选项中不能正确把cl定义成结构体变量的是()。A.typedef struct { in

2022-08-06 02:59:18 问答库 阅读 175 次

问题详情

以下选项中不能正确把cl定义成结构体变量的是()。
A.typedef struct { int red; int green; int blue; } COLOR; COLOR cl;
B.struct color cl { int red; int green; int blue; }
C.struct color { int red; int green; int blue; }cl;
D.struct { int red; int green; int blue; }cl;请帮忙给出正确答案和分析,谢谢!

参考答案

正确答案:B
解析:本题选项A)、C)、D)是定义结构体及其变量的三种正确的形式,能正确将c1定义为结构体变量。选项B)错误。

考点:变量,定义