From 9a2e99daf1f6d79b0d7ba447753e719ff281bc95 Mon Sep 17 00:00:00 2001 From: pan <142723754+111546869@users.noreply.github.com> Date: Mon, 24 Jun 2024 00:04:11 +0800 Subject: [PATCH] Update Student.cpp --- .../src/Student.cpp" | 812 +++++++++--------- 1 file changed, 406 insertions(+), 406 deletions(-) diff --git "a/\345\255\246\347\224\237\347\256\241\347\220\206\347\263\273\347\273\237/src/Student.cpp" "b/\345\255\246\347\224\237\347\256\241\347\220\206\347\263\273\347\273\237/src/Student.cpp" index cf3f136..ecabcbe 100644 --- "a/\345\255\246\347\224\237\347\256\241\347\220\206\347\263\273\347\273\237/src/Student.cpp" +++ "b/\345\255\246\347\224\237\347\256\241\347\220\206\347\263\273\347\273\237/src/Student.cpp" @@ -6,26 +6,26 @@ #include #include #include - +#include using namespace std; ifstream fin; ofstream fout; -//����ѧ������ϵͳ +//建立学生管理系统 void StudentBase::bulidBaseData() { - //��ʾϵͳ�ѽ��� + //提示系统已建立 if(mNum.size() != 0) { system ("cls"); - cout<>str) { if(str == "0") break; - else cout<::iterator it = mPosition.begin();it != mPosition.end();++it) { int pos = it->second; cout<first<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<::iterator it = mPosition.begin();it != mPosition.end();++it) { int pos = it->second; cout<first<>str) { - //�����쳣���� + //输入异常处理 if(str!= "1" && str != "2") { - cout<>str; choose = 0; int n = str.size(); @@ -126,22 +126,22 @@ void StudentBase::modifyData() choose += (str[i] - '0')*pow(10,n-i-1); } if( n > 3 || choose > mNum.size()) correct = 0; - //�����쳣���� + //输入异常处理 if(!correct) { system ("cls"); - cout<::iterator it = mPosition.begin();it != mPosition.end();++it) { int pos = it->second; cout<first<::iterator it = mPosition.begin(); @@ -155,38 +155,38 @@ void StudentBase::modifyData() mPosition.erase(num); cout<>str) { if(str.size() == 1 && str[0] >= '1' && str[0] <= '6') { if(str=="1") { - cout<>num; } else if(str == "2") { - cout<>name; } else if(str == "3") { - cout<>str) { - //�����쳣���� + //输入异常处理 if(str != "0" && str != "1") { - cout<>str) { bool is = 1; if(str.size() != 2 || !isdigit(str[0]) || !isdigit(str[1])) is = 0; - //�����쳣���� + //输入异常处理 if(!is) { - cout<>addr; } else if(str == "6") break; - cout<::iterator it = mPosition.begin();it != mPosition.end();++it) { int pos = it->second; cout<first<second; @@ -327,35 +327,35 @@ FirstA::FirstA() strcpy(mA_MajorDepName,A); }; -//¼��Aϵѧ�����޳ɼ� +//录入A系学生主修成绩 void FirstA::inputA_MajorScore() { - //�쳣��ѧ����Ϣ����ϵͳ��δ���� + //异常,学生信息管理系统尚未建立 if(getmNum().size() == 0) { system ("cls"); - cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str1) { if(str1 == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>num; } fin.close(); - cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>num; } fin.close(); - cout<>str1) { if(str1 == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>num; } fin.close(); - cout<>str1) { if(str1 == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>num; } fin.close(); - cout<>str1) { if(str1 == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>courseNum) { bool is = 1; @@ -1704,17 +1704,17 @@ void StudentMIS::degreeStanderOfFirst() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>courseNum) { bool is = 1; @@ -1729,17 +1729,17 @@ void StudentMIS::degreeStanderOfFirst() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>courseNum) { bool is = 1; @@ -1754,50 +1754,50 @@ void StudentMIS::degreeStanderOfFirst() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>courseNum) { bool is = 1; @@ -1812,17 +1812,17 @@ void StudentMIS::degreeStanderOfSecond() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>courseNum) { bool is = 1; @@ -1837,17 +1837,17 @@ void StudentMIS::degreeStanderOfSecond() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>courseNum) { bool is = 1; @@ -1862,55 +1862,55 @@ void StudentMIS::degreeStanderOfSecond() } cNum += (courseNum[i] - '0')*pow(10,courseNum.size() - i -1); } - //�����쳣���� + //输入异常处理 if(!is) { - cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<>str) { if(str == "0") break; - else cout<getDegree; for(int i=0;i>str) { if(str == "0") break; - else cout<= 60) count++; } - //�γ�������Ҫ�����ѻ������ѧλ�ſɻ�ø���ѧλ + //课程数符合要求且已获得主修学位才可获得辅修学位 if(count >= KA && getDegree.find(num[i])->second) { degree.push_back(num[i]); } } - fout<= 60) count++; } - //�γ�������Ҫ�����ѻ������ѧλ�ſɻ�ø���ѧλ + //课程数符合要求且已获得主修学位才可获得辅修学位 if(count >= KB && getDegree.find(num[i])->second) { degree.push_back(num[i]); @@ -2102,14 +2102,14 @@ void StudentMIS::degree() int age = getAgeAtIndex(pos); string addr = getAddrAtIndex(pos); cout<= 60) count++; } - //�γ�������Ҫ�����ѻ������ѧλ�ſɻ�ø���ѧλ + //课程数符合要求且已获得主修学位才可获得辅修学位 if(count >= KC && getDegree.find(num[i])->second) { degree.push_back(num[i]); @@ -2135,15 +2135,15 @@ void StudentMIS::degree() int age = getAgeAtIndex(pos); string addr = getAddrAtIndex(pos); cout<>str) { if(str == "0") break; - else cout<