class CSR
private data
members:
int csrID – a integer to hold employee identification numbers between 1 and 7.
char *csrName
int hours
int complaintsResolved
float payrate
payRate = $25 + 25*(complaintsResolved by each CSR/total complaints resolved)
float wage – wages = hours * payrate
static int totalComplaintsResolved
1 void calcPayrate() – a function to calculate the employees payrate
2. void calcWage() – a function to calculate the employee’s wage
3. static int getTotalCpsResolved() – a static function to get total complaints resolved
Functions:
1. CSR getCSR_at(CSR employees[7], int index) – returns the CSR object at the given array index
2. void calcTotalComplaints (CSR employees[7] ) – a function that sums the complaints
3. void calcAllEmployeeWages(CSR employees[7])
4. void SortByHours(CSR employees[7]) – sorts employees in descending order based on
hours worked.
5. void SortByComplaintsRes(CSR employees[7]) - similar above
6. void SortByWages(CSR employees[7]) //
Comments
Leave a comment