c/school/ch10_10-5_6_7_8_2.c · 565 字节 · 下载原文
#include <stdio.h>
#include <string.h> // strcpy
#include "public_fun.h"
student Stu[10];
int main(){
char file_path_r[100]="/home/mz/我的/书籍/C语言/谭老C程序设计/第十章/10-5_6_7_8/stud.txt";
char file_path_w[100]="/home/mz/我的/书籍/C语言/谭老C程序设计/第十章/10-5_6_7_8/stusort.txt";
mread(Stu,file_path_r);
sort(Stu);
// 将排好序的数据写入到文件中
write_to_file(Stu,file_path_w);
// corpus fix (2026-11-06): fp1 is local to mread(); it now closes there.
return 0;
}