[单选题]

下面结构体的定义语句中,错误的是

A.)struct ord {int x;int y;int z;}; struct ord a;

B.)struct ord {int x;int y;int z;} struct ord a;

C.)struct ord {int x;int y;int z;} a;

D.)struct {int x;int y;int z;} a;

参考答案与解析:

相关试题

若有结构体定义:struct stu{int num;char sex;int

[单选题]若有结构体定义: struct stu{int num; char sex; int age; }a1,a2; 则下列语句中错误的是( )。A.printf("%d,%c,%d",a1);B.a2.age=a1.age;C.a1.age++;D.a1.num=5;

  • 查看答案
  • 下列定义变量的语句中错误的是A)int _int; B)double int_;

    [单选题]下列定义变量的语句中错误的是A.)int _int;B.)double int_;C.)char For;D.)float US$;

  • 查看答案
  • 若有以下定义的语句 struct student { int age; int

    [单选题]若有以下定义的语句struct student{ int age;int num; };struct student stu[3]={{1001,20},{1002,19},{1003,21}};main(){ struct student *p;p=stu;… }则以下不正确的引用是A.(p++)->numB.p++C.(*p).numD.P=&stu.age.

  • 查看答案
  • 若有以下定义的语句 struct student { int age; int

    [单选题]若有以下定义的语句struct student{ int age;int num; };struct student stu[3]={{1001,20},{1002,19},{1003,21}};main(){ struct student *p;p=stu;… }则以下不正确的引用是A.(p++)->numB.p++C.(*p).numD.P=&stu.age.

  • 查看答案
  • 若有以下定义的语句struct student{int age;int num;

    [单选题]若有以下定义的语句 struct student {int age; int num;}; struct student stu[3]={{1001,20},{1002,19},{1003,21}}; main() {stmct student *p; p=stu; …} 则以下不正确的引用是A.(p++)->numB.p++C.(*p).numD.P=&stu.age.

  • 查看答案
  • 定义结构体数组: struct stu {int num; charname[2

    [单选题]定义结构体数组:struct stu{int num;charname[20];}x[5]={1,"LI",2,"ZHAO",3,"WANG",4,"ZHANG",5,"LIU"};for(i=1;i<5;i++)printf("%d%C",x[i].num,x[i]name[2]);以上程序段的输出结果为( )。A.2A3N4A5UB.112A3H41C.1A2N3A4UD.2H3A4H51

  • 查看答案
  • 若有结构体定义: struct stu {int num; char sex;

    [单选题]若有结构体定义:struct stu {int num;char sex;int age;}a1,a2;则下列语句中错误的是( )。A.printf("%d%c,%d",a1);B.a2.age=a1.age;C.a1.age++;D.a1.num=5;

  • 查看答案
  • 定义结构体数组: struct stu {int num; char name[

    [单选题]定义结构体数组:struct stu{ int num;char name[20];}x[5]={1,"LI",2,"ZHAO",3,"WANG",4,"ZHANG",5,"LIU"};for(i=1;i<5;i++)printf("%d%c",x[i].num,x[i].name[2];以上程序段的输出结果为( )。A.2A3N4A5UB.112A3H41C.1A2N3A4UD.2H3A4H51

  • 查看答案
  • 下面结构体的定义语句中,错误的是()。

    [单选题]下面结构体的定义语句中,错误的是( )。A.struct ord{int x;int y;int z;};struct ord a;B.struct ord{int x;int y;int z;};ord a;C.struct ord{int x;int y;int z;}a;D.struct{int x;int y;int z;}a;

  • 查看答案
  • 下面结构体的定义语句中,错误的是

    [单选题]下面结构体的定义语句中,错误的是A.struct ord{int x;int y;int z;};struet ord a;B.atruet ord{int x;int y;int z;}struct ord a;C.struet ord{int x;int y;int z;}a;D.struct{int x;int y;int z;)a;

  • 查看答案
  • 下面结构体的定义语句中,错误的是A)struct ord {int x;int