设计一个大学教师和学生管理程序,教师包括编号(2)
发布时间:2021-06-06
发布时间:2021-06-06
设计一个大学教师和学生管理程序,教师包
person:input();
cout<<"please zch:";
cin>>zch;
cout<<"please jysh:";
cin>>jysh;
return;
}
void print()
{
person:print();
cout<<setw(10)<<"zch"<<setw(10)<<"jysh"<<endl;
cout<<setw(10)<<zch<<setw(10)<<jysh<<endl;
}
private:
char *zch;
char *jysh;
};
class student:virtual public person
{
public:
void input()
{
person:input();
cout<<"please xb:";
cin>>xb;
cout<<"please bh:";
cin>>bh;
return;
}
void print()
{
student:print();
cout<<setw(10)<<"xb"<<setw(10)<<"bh"<<endl;
cout<<setw(10)<<xb<<setw(10)<<bh<<endl;
}
private:
char *xb;
char *bh;
};
class unstudent: public student
{
public:
void input()