有以下程序#includestdio.hstruct S{int a,b;} data[2]={10,100,20,200};main(){struet S p=data[l];printf(“%d\n”,++(P.a)):}程序运行后的输出结果是A.10B.11C.20D.21

有以下程序

#include<stdio.h>

struct S

{int a,b;} data[2]={10,100,20,200};

main()

{struet S p=data[l];

printf(“%d\n”,++(P.a)):

}

程序运行后的输出结果是

A.10

B.11

C.20

D.21


相关考题:

有以下程序:struct s{ int x,y; }data[2]={10,100,20,200};main(){ struct s *p=data;printf("%d\n",(++p)-x);}程序运行后的输出结果是( )。A.10 B.11 C.20 D.21

下列程序的输出结果是()。includestruct abc{int a, b, c, s;};main(){struct abc s[2] 下列程序的输出结果是( )。 #include <stdio.h> struct abc { int a, b, c, s;}; main() { struct abc s[2]={{1,2,3},{4,5,6}}; int t; t=s[0].a+s[1].b; printf("%d\n",t); }A.5B.6C.7D.8

有以下程序}struct s{ int x,y; } data[2]={10,100,20,200};}main( )}{ struct s *p=data;}printf("%d\n",++(p->x));}程序运行后的输出结果是A.10B.11C.20D.21

有以下程序:include struet STU{charname[10]; int num; float TotalSeore; };void f( 有以下程序:#include <stdio.h>struet STU{ charname[10]; int num; float TotalSeore; };void f(struet STU * p){ struet STU s [2] = { { "SunDan" ,20044,550 } , { "Penghua" ,20045,537 } } , * q = s; ++p; ++q; *p= *q;}main( ){ struct STU s[3] = { { "YangSan" ,20041,703 }, { "LiSiGuo" ,20042,580} }; f(s) ;printf("% s % d % 3.Of\n" ,s [1]. name, s [1]. num ,s [1]. TotalScore);}程序运行后的输出结果是( )。A.SunDan 20044 550B.Penghua 20045 537C.LiSiGuo 20042 580D.SunDan 20041 703

有以下程序: include struct STU {int num; float TotalScore; 有以下程序: #include <strino.h> struct STU {int num; float TotalScore; }; void f(struct STU p) {struct STU s[2]={{20044,550},{20045,537}}; p.num=s[1].num;p.TotalScore=s[1].TotalScore; } main() {struct STU s[2]={{20041,703},{20042,580}}; f(s[0]); printf("%d%3.0t\n",s[0].num,s[0].TotalScore); } 程序运行后的输出结果是 ______。A.20045 537B.20044 550C.20042 580D.20041 703

有以下程序: include struct STU (char name[10]; int num; }; 有以下程序: #include <string.h> struct STU (char name[10]; int num; }; void f(char *name, int num) {struct STU s[2]={{"SunDan",20044}.{"Penghua",20045}}; num=s[0].num; strcpy(name,s[0].name); } main() {struct STU s[2]={{"YangSall",20041},{"LiSiGao",20042}},*p;p=s[1]; f(p->name,p->num); printf("%s%d\n",p->name,p->num); } 程序运行后的输出结果是 ______。A.SunDan 20042B.SunDan 20044C.LiSiGuo 20042D.YangSan 20041

有以下程序 include struct tt { int x; struct tt *y; } *p; s 有以下程序 #include <stdio.h> struct tt { int x; struct tt *y; } *p; struct tt a[4]= {20,a+ 1,15,a+2,30,a+3,17,a}; main() { int i; p=a; for(i=1; i<-2; i++) { printf("%d,", p->x ); p=p->y; }A.20,30,B.30,17C.15,30,D.20,15,

若有以下程序段: struct st {int n; int*m: }; int a=2,b=3,c=5; struct st s[3]=({101,a},{102,c},{103,B)}; main() {struct st*p; p=s; } 则以下表达式中值为5的是( )。A.(*p).mB.*(p+1)->mC.*(p++)->nD.(p++)(*m)

有以下程序: include include struct NODE {int num;struct NODE *next; } 有以下程序:#include <stdio.h>#include <stdlib.h>struct NODE{ int num;struct NODE *next;};main(){ struet NODE *p,*q,*r;int sum=0;p=(struct NODE *) malloc(sizeof(struct NODE));q=(struct NODE *) malloc(sizeof(struet NODE));r=(struct NODE *) malloc(sizeof(struct NODE));P- >num=1;q- >num=2;r->num=3;p- >next=q;q- >next=r;r- >next=NULL;sum + =q- >next- >num;sum + =P- >num;printf("%d\n",sum);}执行后的输出结果是( )A.3B.4C.5D.6

有以下程序:includeint a=2;int f(int *a){return (*a) ++;}main(){ int s=0;{ int a= 有以下程序: #include <stdio.h> int a=2; int f(int *a) { return (*a) ++;} main() { int s=0; { int a=5; s+=f(a); } s+=f(a); printf("%d\n",s) } 执行后的输出结果是( )。A.10B.9C.7D.8

有以下程序 include struct st { int x,y;} data[2]={1,10,2,20}; main( 有以下程序 #include <stdio.h> struct st { int x,y;} data[2]={1,10,2,20}; main() { struct st *p=data; printf("%d,",p->y); printf("%d\n",(++p)->x); } 程序的运行结果是______。A.10,1B.20,1C.10,2D.20,2

有以下程序#includestdio.hstruct S{int a,b;} data[2]={10,100,20,200};main(){struet S p=data[l];printf(“%d\n”,++(P.a)):}程序运行后的输出结果是A.10B.11C.20D.21

有以下程序:#includestdio.hstruct S{int a,b;)data[2]=10,100,20,200);main( ){struct S p=data[l];printf(%d\n,++(p.a));}程序运行后的输出结果是( )。A.10B.11C.20D.21

有以下程序:struct S{int n;int a[20];};void f(struct S*P){int i,j,t;for(i=0;in-1;i++)fo 有以下程序: struct S{int n;int a[20];}; void f(struct S*P) { int i,j,t; for(i=0;i<P->n-1;i++) for(j=j+1;j<P->n-1;j++) if(p->a[i]>p->a[j]) {t=P->a[i];p->a[i]=P->a[j];p->a[j]=t} } main() {int i;struct S s{10,{2,3,1,6,8,7,5,4,10,9}}; f(&s); for(i=0;i<s.n;i++)printf("%d",s.a[i]);} 程序运行后的输出结果是( )。A.3B.4C.5D.6

以下程序的输出结果是( )。include struct s { int x,y; } a[2]={10,100,20,200}; main() { struct s *p=data; printf("%d\n",++(p->x)); } A、10B、11C、20D、21

有以下程序 include struct NODE {int num;struct NODE*next;} main() {struct NODE 有以下程序#include<stdlib.h>struct NODE{int num;struct NODE*next;}main(){struct NODE *P,*q,*r;p=(struct NODE *)malloc(sizeof(struct NODE));q=(struct NODE *)malloc(sizeof(struet NODE));r=(struct NODE*)malloc(sizeof(struct NODE)):p->num=10;q->num=20;r->num=30;p->next=q;q->next=r;printf("%d\n",p->num+q->next->num):}程序运行后的输出结果是( )A.10B.20C.30D.40

以下程序的功能是:建立一个带有头结点的单向链表,并将存储在数组中的字符依次转存到链表的各个结点中,请填空。 #include <stdlib.h> stuct node { char data; struet node * next; }; stntct node * CreatList(char * s) { struet node *h,*p,*q; h = (struct node * ) malloc(sizeof(struct node) ); p=q=h; while( * s! ='\0') { p = (struct node *) malloc ( sizeof(struct node) ); p - > data = ( ) q- >next=p; q=p; a++; p- > next ='\0'; return h; } main( ) { char str[ ]= "link list"; struet node * head; head = CreatList(str);A.*sB.sC.*s++D.(*s)++

有以下程序:include include struet STU{ int nam;float TotalSeore;};v 有以下程序:#include <stdio, h>#include <string, h>struet STU{ int nam; float TotalSeore;};void f( strnct STU p){ struct STU s[2] = { {20044,550} ,{20045,537} }; p.num = s [1]. num; p.TotalScore = s [1]. TotalScore;main( ){ struct STU s[2] = {{20041,703} ,{20042,580}}; f(s[0] ); printf( "%d %3.Of\n" ,s[0].num,s[0].TotalSeore); }程序运行后的输出结果是( )。A.20045 537B.20044 550C.20042 580D.20041 703

(38)有以下程序#include stdio.hstruct S{ int a,b;}data[2]={10,100,20,200};main(){ struct S p=data[1];printf("%d\n",++(p.a));}程序运行后的输出结果是A)10B)11C)20D)21

以下C语言程序的输出结果是( )。struct s{int x,y;}data[2]={10,100,20,200};main( ){struct s*p=data;p++;printf(“%d\n”,++(p->x));}A.10B.11C.20D.21

以下程序段的输出结果是()。      struct node         {int a;  float b;  char c[10];}  printf(“%d”,sizeof(struet node)) ;

单选题有以下程序:#include struct S{ int a,b;}data[2]={10,100,20,200};main(){ struct S p=data[1]; printf(%d,++(p.a));}程序运行后的输出结果是(  )。A10B11C20D21

单选题有以下程序:#include struct S{ int x,y;};main(){ struct S data[3] = {4,3,2,0,8,1}; int i; for(i=0;i3;i++)  printf(%d%d;,data[i].x, data[i].y1); printf();}程序运行后的输出结果是(  )。A41;20;80;B41;22;64;C40;21;80;D43;20;81;

单选题有如下程序:#include #include struct S{ char name[10];};void change(struct S *data,int value){ strcpy(data-name, ****); value=13;}main(){ struct S input; int num = 4; strcpy(input.name, THIS); change(input,num); printf(%s,%d,input.name,num);}程序运行后的输出结果是(  )。A****,4B****,13CTHIS,4DTHIS,13

单选题有以下程序:#include struct st{ int x,y;} data[2]={1,10,2,20};main(){ struct st *p=data; printf(%d,,p-y); printf(%d,(++p)-x);}程序运行的结果是(  )。A10,1B20,1C10,2D20,2

单选题有以下程序#include #include struct S{ char name[10];};void change(struct S *data, int value){ strcpy(data-name, #); value = 6;}main(){ struct S input;  int num = 3; strcpy(input.name, OK); change(input, num); printf(%s,%d, input.name, num);}程序运行后的输出结果是(  )。AOK,6B#,6COK,3D#,3

单选题有如下程序:#include struct S{ int x,y;};main(){ struct S data[2] = {4,3,1,9}; int i; for(i=0;i2;i++)  printf(%d,%d;,data[i].x, data[i].y1);}程序运行后的输出结果是(  )。A4,1;1,4;B4,1;2,4;C4,3;1,9;D4,3;2,3;

单选题有以下程序:#include struct link{ int data; struct link *next;};main(){ struct link *h,a,b; h=a; a.data=10; a.next = b; b.data = 20;}程序运行时不能输出10,20的语句是(  )。Aprintf(%d,%d,h-data,a.next.data);Bprintf(%d,%d,a.data,(*a.next).data);Cprintf(%d,%d,h-data,(*a.next).data);Dprintf(%d,%d,a.data,a.next-data);