#include
#include
#include
#include
#include
#include
using namespace std;
struct Staff {
string name;
string sex;
string birth;
int age;
string marital;
string address;
string title;
int salary;
};
//
void print_staff(const Staff staff) {
cout staffs) {
int size = staffs.size();
double total = 0;
//
for (int i = 0;i staffs) {
int size = staffs.size();
int j;
for (int i = 1;i = 0 staffs[j].salary staffs) {
int size = staffs.size();
//()
set levels;
set::iterator it;
for (int i = 0;i staffs) {
int size = staffs.size();
int number = 1;
for (int i = 0;i staffs) {
ifstream in("staffs.txt", ifstream::in);
if (!in.is_open()) {
cout > staff.name >> staff.sex >> staff.birth >> staff.age >> staff.marital >> staff.address >> staff.title >> staff.salary;
staffs.push_back(staff);
}
int size = staffs.size();
cout staffs;
int opt;
while (1) {
cout > opt;
if (opt 5) {
cout << "" << endl;
} else if (opt == 1) {
load_staffs(staffs);
} else if (opt == 2) {
stat_salary(staffs);
} else if (opt == 3) {
sort_salary(staffs);
cout << ":" << endl;
display_staffs(staffs);
} else if (opt == 4) {
same_salary_level(staffs);
} else {
cout << "" << endl;
break;
}
}
return 0;
}