9. Write a program: There are 3 students, and each student has 4 courses. After the user is required to input the student serial number, all the grades of the student can be output. Using pointer functions to realize learning...

It can be implemented like this: #include <stdio.h>struct student{ int num; // student serial number int score[4]; // score}; void input(struct student *p, int n); // input score void output (struct student *p); //Output score int main(){ struct student stu[3]; //Define 3 students input(stu,3); //Input score int num; while(1){ printf( "Please enter the student serial number:");

Guess you like

Origin blog.csdn.net/weixin_35751412/article/details/129510999