[单选题]

有以下程序: 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 537

B.20044 550

C.20042 580

D.20041 703

参考答案与解析:

相关试题

有以下程序:struct STU{char name[10];int num;}

[单选题]有以下程序: struct STU{ char name[10]; int num; }; void f1(struct STU c) { struct STU b={"LiSiGuo",2042); c=b; } void f2(struct STU *c) { struct STU b={"SunDan",2044); *c=b; } main() {struct STU a={"YangSan",2041},b={"WangYin",2043); f1(a);f2(&

  • 查看答案
  • 有以下程序: struct STU {char name[10];int num

    [单选题]有以下程序: struct STU {char name[10];int num;float TotalScore;}; void f(struct STU *p) {struct 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(

  • 查看答案
  • 有以下程序struct STU{char name[10];int num;in

    [单选题]有以下程序struct STU{ char name[10]; int num; int Score;};main(){ struct STU s[5]={{"YangSan",20041,703}, {"LiSiGuo",20042,580}, {"WangYin",20043,680}, {"SunDan",20044,550}, {"Penghua",20045,537}}, *p[5], *t; int i,j; for(i=0;i<5;i++) p[i]=&a

  • 查看答案
  • 有以下程序struct STU{ char name[10]; int num;

    [单选题]有以下程序 struct STU { char name[10]; int num; int Score; { main() { struct Stu s[5]={{"YangSan",20041,703},{"LiSiGuo",20042,580}, {"WangYin",20043,680},{"SunDan",20044,550}, {"Penghua",20045;537}},*p[5],*t; int i,j; for(i=0;i<5;i++)p[i]=&s

  • 查看答案
  • 有以下程序struct STU{char name[10];int num;};

    [单选题]有以下程序 struct STU{ char name[10]; int num; }; void f1(struct STU C) { struct STU b={"LiSiGuo",2042}; c=b; } void f2(struct STU*C) { struct STU b={"SunDan",2044}; *c=b; } main() { struct STU a={"YangSan",2041},b={"Wang Yin",2043}; f1(a) ;f2(&am

  • 查看答案
  • 有以下程序:struct STU{ char name[10];int num;

    [单选题]有以下程序: struct STU { char name[10]; int num; float TotalScore; }; void f(struct STU *p) { struct STU s[2]={{"SunDan", 20044, 550}, {"Penghua", 20045, 537}}, *q=s; ++p; ++q; *p=*q; } main() { struct STU s[3]={{"YangSan", 20041, 703}, {"LiSiGuo"

  • 查看答案
  • 有以下程序: #include struct NODE{ int num; st

    [单选题]有以下程序: include struct NODE{ int num; struct NODE*next; } main() {structNOD有以下程序:#include<stdlib.h>struct NODE{int num;struct NODE *next;}main(){ struct NODE *p,*q,*r;int sum=0;p=(struct NODE *)malloc(sizeof(struct NODE));q=(Struct NODE *)malloc(sizeo

  • 查看答案
  • 有以下程序 #include struct NODE {int num;stmc

    [单选题]有以下程序 include struct NODE {int num;stmct NODE*next;}; main() { struct NODE有以下程序#include<stdlib.h>struct NODE{ int num;stmct NODE*next;};main(){ struct NODE*p,*q,*r;p=(struct NODE*)malloc(sizeof(struct NODE));q=(struct NODE*)malloc(sizeof(struct NODE)

  • 查看答案
  • 有以下程序 #include struct NODE { int num;str

    [单选题]有以下程序 include struct NODE { int num;struct NODE*next;}; main() { struct NO有以下程序#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(struct NODE

  • 查看答案
  • 有以下程序 #include struct NODE{ int num; st

    [单选题]有以下程序 include struct NODE{ int num; struct NODE *next;}; main( )有以下程序#include <stdlib.h>struct NODE{int num;struct NODE *next;};main( ){ struct NODE *p,*q,*r;int sum=0;p=(struct NODE *)malloc(sizeof(struct NODE));q=(struct NODE *)malloc(sizeof(struc

  • 查看答案
  • 有以下程序: #include  struct STU {int num; fl