mirror of
https://github.com/renbaoshuo/202401-programming-assignments.git
synced 2024-12-16 15:44:39 +00:00
13 lines
262 B
C
13 lines
262 B
C
|
struct student fun(struct student *std, char *num) {
|
||
|
struct student res = {"\0", 0, 0, 0};
|
||
|
|
||
|
for (int i = 0; i < N; i++) {
|
||
|
if (strcmp(std[i].num, num) == 0) {
|
||
|
res = std[i];
|
||
|
break;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
return res;
|
||
|
}
|