#include<stdio.h>
int main()
{
struct stdent
{
long num;
char name[20];
int score[4];
}st;
int i;
scanf("%ld%s",&st.num,st.name);
for(i=0;i<4;i++)
scanf("%d",&st.score[i]);
printf("%10ld\n%-20s\n",st.num,st.name);
for(i=0;i<=3;i++)
printf(" %5d",st.score[i]);
printf("\n");
return 0;
}
/*vc++6.0:
211906326 leixiaohua
90 85 74 85
211906326
leixiaohua
90 85 74 85
Press any key to continue
*/
C语言结构体存放:学生学号、姓名、四个成绩
最新推荐文章于 2024-01-16 21:34:12 发布