题目:学生学籍管理系统

来源:百度知道 编辑:UC知道 时间:2024/05/29 13:27:50
功能要求:
1.录入:能够录入学生信息,包括学号,姓名,性别,语文成绩,数学成绩和计算机成绩,录入的信息保存在数据库或者文件中;
2.显示:能够将所有学生的信息显示在屏幕上,显示的信息中,除上述各条外,还应该包括三门课程成绩的平均成绩;
3.查找:能够根据学号和姓名分别查找符合条件的条目;
4.删除:能够根据学号从数据库或者文件中删除一条学生信息;
5.排序:能够分别根据三门成绩和平均成绩对所有的条目进行排序

基本上满足你的要求你再自己改一下吧!

#include <iostream>
#include <string>
#include<fstream>
#include<iomanip>
using namespace std;
int amount=0; //记录学生个数
ofstream *file[50];
/////////////////////////////////*学生成绩结构体*////////////////////////////////////////
struct score
{
float yw;
float sx;
float yy;
float wl;
float hx;
float sw;
struct score *next;
};
/////////////////////////////////*学生数据类*////////////////////////////////////////
class student
{
public:
string mun;
string name;
score sc1;
score sc2;
score sc3;//平时成绩,期末成绩,总成绩;
class student *next;
};
/////////////////////////////////*函数声明*////////////////////////////////////////
void input(student *head); //录入
void search1(student *head); //姓名查询
void search2(student *head); //学号查询
void change(student *head); //修改