#includestruct student{ char name[20]; char num[20]; char porject[20]; double grade;};void main(){ int i;student str[3]; for(i=0;i<3;i++) { printf("第%d个学生的信息是:\n",i+1); printf("姓名:");scanf("%s",str[i].name); printf("学号:");scanf("%s",str[i].num); printf("系别:");scanf("%s",str[i].porject); printf("成绩:");scanf("%lf",&str[i].grade); } for(i=0;i<3;i++) { printf("第%d个学生的信息是:\n",i+1); printf("姓名:%s\n",str[i].name); printf("学号:%s\n",str[i].num); printf("系别:%s\n",str[i].porject); printf("成绩:%lf\n",str[i].grade); }}
#includestruct student { char sno[10]; char sname[20]; int age;};int main(){ student class3[31]; int i=0,j; FILE *fp=fopen("d:\\input.txt","r"); while(!feof(fp))return 0; }