关于结构体成员变量Id内容或地址,下面的使用非法的是() struct Student { int Id; }stu,*p;A.Student.IdB.(p->Id)C.p->IdD.stu.Id

关于结构体成员变量Id内容或地址,下面的使用非法的是() struct Student { int Id; }stu,*p;

A.Student.Id

B.&(p->Id)

C.p->Id

D.stu.Id


参考答案和解析
Student.Id

相关考题:

已知Student类有一个属性__id,stu是Student类的对象,则通过“stu.__id='1810101'”可以将stu对象中的__id属性赋值为字符串'1810101'。() 此题为判断题(对,错)。

设有定义:struct person{ int ID;char name[12];}p;请将 scanf("%d", 【 1 2 】 ); 语句补充完整,使其能够为结构体变量 p 的成员 ID 正确读入数据。

设有以下说明语句struct stu{int a;float b;} stutype;则下面的叙述不正确的是A.struct是结构体类型的关键字B.struct stu是用户定义的结构体类型C.stutype是用户定义的结构体类型名D.a和b都是结构体成员名

有以下说明和定义语句 struct student { int age;char num[8]; struct student stu[3]={{20,"200401"},{21,"200402"},{19,"200403"}}; struct student *p=stu;}; 以下选项中引用结构体变量成员的表达式错误的是A.(p++)->numB.p->numC.(*p).numD.stu[3].age

若有以下定义的语句 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.

若有下列说明和语句,则对结构体变量st中成员i的引用方式不正确的是( )。Stmct stu{ int i;int name;}st,*p;p=st;A.st.iB.*p.iC.(*p).iD.p->i

下列说法错误的是( )。A.下列结构体定义时,占据了5个字节的空间 struct student “nt num; int age; char sex; }B.结构体的成员名可以与程序中的变量名相同C.对结构体中的成员可以单独使用,它的作用相当于普通变量D.结构体可以嵌套定义

若有下列说明和语句,则对结构体变量st中成员i的引用方式不正确的是( )。Struct stu{inti;intname;}st,*#p;p=St;A.st.iB.*p.iC.(*p).iD.p->i

struct{int num;float scor;}student;struct student std1;是对结构体类型的变量student的定义。() 此题为判断题(对,错)。

若有以下定义的语句: 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.

下列说法错误的是( )。A.下列结构体定义时,占据了5个字节的空间 struct student {int num; int age; char sex; }B.结构体的成员名可以与程序中的变量名相同C.对结构体中的成员可以单独使用,它的作用相当于普通变量D.结构体可以嵌套定义

设有定义:struct person{int ID;char name[12];}P;请将scanf(“%d”, 【 】);语句补充完整,使其能够为结构体变量P的成员ID正确读人数据。

以下对结构体变量mix中成员x的正确引用是______。 struct { int t;int x; }mix,*p; p=mix;A.(*p).mix.xB.(*p).xC.p->mix.xD.p.mix.x

若有下列说明和语句,则对结构体变量st中成员i的引用方式不正确的是( )。 Struct stu { int i; int name; }st,*p; p=st;A.st.iB.*p.iC.(*p).iD.p->i

有以下说明和定义语句struct student{ int age; char num[8];};struct student stu[3]={{20,"200401"},{21,"200402"},{10\9,"200403"}};struct student *p=stu;以下选项中引用结构体变量成员的表达式错误的是A.(p++)-num B.p-num C.(*p).num D.stu[3].age

有以下说明和定义语句:struct student{int age; char num[8] ;};struct student stu [3] = { { 20, "200401" } , {21, "200402" } , {19, "200403" } };stract student * p = stu;以下选项中引用结构体变量成员的表达错误的是( )。A.(p++) ->numB.p- >numC.( *p).numD.stu[3].age

若有以下说明和语句: struct student{          int age;          int num;  }std, *p;  p=std;  则下面对该结构体变量std中成员age的引用方式错误的是()。 A、std.ageB、*p.ageC、(*p).ageD、p-age

有下列语句:  struct Birthday{public int year;  public int month;   public int day;}; struct Student{ int no;  string name;   int age;  public Birthday bir; };  ……  Student Stu;  如果要把Stu的出生年份赋值为1988,正确的语句是()A、 Stu.bir.year=1988;B、 Stu.year=1988;C、 Stu. Birthday.year=1988;D、 Student. Birthday.year=1988;

设有C语句:struct T{int n;double x;}d,*p;,若要使p指向结构体变量中的成员n,正确的赋值语句是()A、p=d.nB、*p=d.nC、p=(struct T *)d.nD、p=(struct T *)d.n

数据结构里,struct student { char name[20]; char sex[10]; int age; int score; }; 定义结构体后,定义变量、数组赋值正确的是()。A、struct student s={"张三","男",18,100};B、struct student stu[3]={{"张三","男",18,100},{"李四","男",19,90},{"王五","男",23,97}};C、struct student s={"李四";"女";18;100};D、struct student stu[3]={{"张三",18,"男",100},{"李四",19,"男",90},{"王五",23,"男",97}};

数据结构中,struct pro { int id; char name[20]; }; void fun(struct pro p[]) { ......;//函数体省略 }关于本程序段描述不正确的是()。A、fun函数是按照值传递进行的B、fun函数是结构体数组作为参数C、结构体数组做参数,属于地址传递D、数组p做参数传递是数组的首地址

有以下说明语句:struct Student{int num;double score;};Student stu[3]={{1001,80},{1002,75},{1003,91}},*p=stu;则下面引用形式错误的是()A、p-numB、(p++).numC、(p++)-numD、(*p).num

现有学生住处表Student_info,其中包括姓名(stu_name),学号(stu_id),成绩(stu_grade)。我们需要查询成绩为80分的学生姓名,要求结果按照学号降序排列。下面查询语句正确的是()。A、SELECT stu_name FROM student_info Where stu_grade=80 ORDER BY stu_id ASC;B、SELECT stu_name FROM student_info WHERE stu_grade=80 ORDER BY stu_id DESC;C、SELECT stu_id,stu_name FROM student_info WHERE stu_grade=80 ORDER BY stu_name ASC;D、SELECT stu_name FROM student_info WHERE stu_grade LIKE 80 ORDER BY stu_id DESC;

单选题若有以下说明和语句: struct student{          int age;          int num;  }std, *p;  p=std;  则下面对该结构体变量std中成员age的引用方式错误的是()。Astd.ageB*p.ageC(*p).ageDp-age

单选题有以下说明语句:struct Student{int num;double score;};Student stu[3]={{1001,80},{1002,75},{1003,91}},*p=stu;则下面引用形式错误的是()Ap-numB(p++).numC(p++)-numD(*p).num

单选题以下scanf函数调用语句中对结构体变量成员的不正确引用的是()。  struct node{      char name[20];      int age;      int sex; }student[5],*p;  p=student;Ascanf(“%s”,student[0].name);Bscanf(“%d”,student[0].age);Cscanf(“%d”,(p-sex));Dscanf(“%d”,p-age);

单选题数据结构中,struct pro { int id; char name[20]; }; void fun(struct pro p[]) { ......;//函数体省略 }关于本程序段描述不正确的是()。Afun函数是按照值传递进行的Bfun函数是结构体数组作为参数C结构体数组做参数,属于地址传递D数组p做参数传递是数组的首地址

多选题数据结构里,struct student { char name[20]; char sex[10]; int age; int score; }; 定义结构体后,定义变量、数组赋值正确的是()。Astruct student s={张三,男,18,100};Bstruct student stu[3]={{张三,男,18,100},{李四,男,19,90},{王五,男,23,97}};Cstruct student s={李四;女;18;100};Dstruct student stu[3]={{张三,18,男,100},{李四,19,男,90},{王五,23,男,97}};