首页/ 题库 / [单选题]若有以下定义的语句 struct stu的答案

若有以下定义的语句 struct student {int age; int num;}; struct student stu[3]={{1001,20},{1002,19},{1003,21}}; main() {stmct student *p; p=stu; …} 则以下不正确的引用是

单选题
2022-11-04 14:49
A、(p++)->num
B、p++
C、(*p).num
D、P=&stu.age.
查看答案

正确答案
D

试题解析

标签:
感兴趣题目
以下程序的输出结果是______。#include<stdio.h>struct stu{ int num; char name[10]; int age;};void fun(struct stu*p){ printf("%s ",(*p).name);}main(){ struct stu students[3]={ {9801,"Zhang",20}, { 9802,"Wang",19}, { 9803,"Zhao",18} }; fun(students+2);}
有以下程序: #include<<stdio.h> struct stu { int num; char name[10]: int age;} void fun(struct stu*p) {printf("%s\n",(*p).name);} the main { struct stu students[3]={{9801,"Zhang".20}, {9802,"Wang",19},{9803,"Zhao",1 8}} fun(students+2); } 输出的结果是( )。
有以下定义和语句:
struct workers   
{int num;char name[20];char C;
 struct
 {int day;int month;int year;)S;
};
struct workers w,*pw;
pw=&w;
能给w中year成员赋1980的语句是(  )。
有如下定义struct person {char name[9];int age;};struct person class[10]={"John",17,"paul",19,"Mary",18,"Adam",16,};根据上述定义,能输出字母M的语句是
有如下定义: struct person {char name[9];int age;}; struct person class[10]={"John",17,"paul",19,"Mary",18,"Adam",16}; 根据上述定义,能输出字母M的语句是( )。
有如下定义struct person{char name[9];int age;};struct person class[10]={"John",17,"paul",19,"Mary",18,"Adam",16,};根据上述定义,能输出字母M的语句是
有以下说明和定义语句 struct student { int age; char num[8];}; struct student stu[3]={{20,"200401"},{21,"200402"},(19,"200403"}}; struct student*p=stu; 以下选项中引用结构体变量成员的表达式错误的是______。
有以下说明和定义语句struct student{ int age;char num {8};};struct student stu[3]={{20,“200401”},{21,“200402”),{19,“200403”}};struct student *p=stu; 以下选项中引用结构体变量成员的表达式错误的是
有以下说明和定义语句:struct student{int age; char num[8] ;};struct student stu [3] = { { 20, "200401" } , {21, "200402" } , {19, "200403" } };stract student * p = stu;以下选项中引用结构体变量成员的表达错误的是( )。
有以下说明和定义语句 struct student { int age;char num[8]; struct student stu[3]={{20,"200401"},{21,"200402"},{19,"200403"}}; struct student *p=stu;}; 以下选项中引用结构体变量成员的表达式错误的是
有以下说明和定义语句 struct student {int age;char num[8]; }; struct student stu[3]={{20,"200401"},{21,"200402"},{109,"200403"}}; struct student*p=stu;以下选项中引用结构体变量成员的表达式错误的是______。
若有以下定义的语句 struct student {int age; int num;}; struct student stu[3]={{1001,20},{1002,19},{1003,21}}; main() {stmct student *p; p=stu; …} 则以下不正确的引用是
相关题目
以下对结构变量stul中成员age的非法引用是() struct student  { int age;  int num;  }stu1,*p;  p=&stu1;
struct st {int age;int num;}stul, p; p=&stul;以下对结构体变量stul中成员age的非法引用是( )
设有如下定义,下面输入语句中,( )错误。struct ss { char name[10];int age;char sex;}std[3],p=std;
有如下定义:struct person{char name[9]; int age;};struct person class[10]={“Johu”, 17,“Paul”, 19,“Mary”, 18,“Adam 16,};根据上述定义,能输出字母M的语句是 ( )
若有定义语句:int a[2][3],*p[3];,则以下语句中正确的是(  )。
若有以下结构体定义,则______是正确的引用或定义。 struct example { int x; int y; }v1;
若有以下结构体,则正确的定义或引用的是struct Test{int x;int y;} vl;
若有以下语句:typedef struct S{int 9;char h;}T;以下叙述中正确的是( )。
若有以下语句typedef struct S{int g;char h;}T;以下叙述中正确的是( )。
若有定义语句:int a[2][3],*p[3];,则以下语句中正确的是(  )。
若有定义语句:int a[2][3],*p[3];,则以下语句中正确的是( )。
若有定义语句:int a[21[3],* P[3];则以下语句中正确的是( )。
若有定义语句:int a[2][3],*p[3];,则以下语句中正确的是( )。
若有定义语句:int k[2][3],*pk[3];,则以下语句中正确的是( )。
若有定义语句:int a[2][3],*p[33;,则以下语句中正确的是( )。
若有定义语句: int a[2][3],*p[3]; ,则以下语句中正确的是
若有定义语句: int k[2][3],*pk[3]; , 则以下语句中正确的是
有以下程序段: typedef struct NODE { int num; struct NODE * nex; } OLD; 以下叙述中正确的是( )。
以下程序的输出结果是 ( ) #include<stdio.h> main() {struct stru{int a,b: char c[6]; }: printf("%d ",sizeof(stru)), }
设有以下说明语句 struct num { int a; float b; }numl;则下面的叙述不正确的是______。
广告位招租WX:84302438

免费的网站请分享给朋友吧