设计一个C++程序,教学管理系统。

来源:百度知道 编辑:UC知道 时间:2024/07/02 08:37:35
学生信息包括学生的班级代号,学好和姓名,选课信息包括每个学生该学期所选的课程,成绩包括每个学生所选的课程的考核成绩。系统功能要求如下:1,能输入学生信息、选课信息和成绩。2,能输出个班某门课程不及格的名单(含学号、姓名和成绩)3,能输出某门课程全年级前5名的学号、姓名和成绩。4,能输出某门课程每个班的总平均分(从高到低排列)。5,能输出某门课程某班的成绩单(按学号排列)
我需要的是设计的程序 源文件内容 非诚勿扰!

#include<fstream.h>
#include<iostream.h>
#include<iomanip.h>
class student
{
private:
int no;
char name[10];
int score;
char sex[2];
int age;
int banji;
public:
void getdata()
{
cout<<" (学号 姓名 成绩 性别 年龄 班级) :";
cin>>no>>name>>score>>sex>>age>>banji;
}
int getno()
{
return no;
}
int getage()
{
return age;
}
void disp()
{
cout<<setw(6)<<no<<setw(10)<<name<<setw(6)<<score<<setw(4)<<age<<setw(6)<<sex<<setw(6)<<banji<<endl;
}
};
void func1()
{
ofstream output("stud.dat");
student s;
int n;
cout<<"输入数据"<<endl;
cout<<" 学生人数:";
cin>>n;
for (int i=0;i<n;i++)