Files
2023-07-28 22:53:00 +08:00

19 lines
320 B
C++

#include"3.23.h"
Person dancer[MAXQSIZE];
int main() {
int i = 0;
fstream file;
file.open("DancePartner.txt");
if (!file) {
cout << "错误!未找到文件!\n\n" << endl;
exit( ERROR);
}
while (!file.eof()) {
file >> dancer[i].name >> dancer[i].sex;
i++;
}
DancePartner(dancer, i + 1);
return 0;
}