📄 mang.h
字号:
class manager:virtual public employee{
protected:
float monthlypay,sale;
public:
manager(){monthlypay=8000;}
void input(){cout<<"经 理 ";employee::input();}
void save(){
fstream outfile;
outfile.open("F:shuju.txt",ios::app);
if(!outfile){
cout<<"F can't open.\n";
abort();
}
outfile<<"经 理"<<endl;
outfile<<"号 码"<<no<<"名 字"<<name<<"性 别"<<sex<<"年 龄"<<age<<"工 资"<<salary<<endl;
}
void pay(){salary=monthlypay;}
void print(){
cout<<"├—————┼—————┼—————┼—————┼—————┤"<<endl;
cout<<"│"<<setw(10)<<no<<"│"<<setw(10)<<name<<"│"<<setw(10)<<sex\
<<"│"<<setw(10)<<age<<"│"<<setw(10)<<salary<<"│"<<endl;
}
};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -