Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ WITH HEADER FILE AND MAIN PROGRAM In this assignment you will be creating the code for several classes in order to implement a payroll

C++ WITH HEADER FILE AND MAIN PROGRAM

In this assignment you will be creating the code for several classes in order to implement a payroll program for a hospital. The program calculates the salaries for employees and volunteers. The program uses the following classes to achieve this goal:

* The StaffMember class: an abstract class that does not represent a particular type of employee. It is the ancestor of all employee classes, so it has the information that is shared among all employees.

* The Volunteer class: Volunteers work on special events and they are not paid. So this class represents a person who is not compensated monetarily for his or her work. It keeps track of only the basic information of a volunteer.

* The Employee class: represents an employee who gets paid at a particular rate each pay period.

* The Doctor class: represents an employee who earns 10% of the total costs of each surgery he or she may perform in addition to the normal pay rate.

* The Nurses class: represents an employee who is paid on hourly basis.

* The Executive class: represents an employee who may earn a bonus in addition to his or her normal pay rate.

* The Receptionist class: represents an employee who are paid their normal pay rate only.

* The driver file Hospital (where the main() is) creates a staff of employees and calls the pay() function to pay them. When the program is run, it should display the information about each employee and how much he/she should be paid.

Create the following StaffMember objects in order to find their pay rates:

Volunteer -> Name: Diana, Address: 11 South Paris Hill Rd., Phone: (984) 163-0125.

Volunteer -> Name: Ryan, Address: 625 Amerige Dr., Phone: (750) 837-4154.

Doctor -> Name: Gene, Address: 311 Delaware Ave., Phone: (275) 249-0721, SSN: 047-86-8586, Pay Rate: 150.0 $/hr, Number of working hours: 160, Surgeries: 3, Cost of each surgery: $10,000.

Nurse -> Name: Raye, Address: 933 Honey Creek St., Phone: (722) 521-3317, SSN: 417-46-7995, Pay Rate: 50.5 $/hr, Number of working hours: 80.

Nurse -> Name: Kristopher, Address: 99 Harvard St., Phone: (672) 790-2499, SSN: 517-42-5738, Pay Rate: 45.9 $/hr, Number of working hours: 100.

Nurse -> Name: Kristopher, Address: 99 Harvard St., Phone: (672) 790-2499, SSN: 517-42-5738, Pay Rate: 45.9 $/hr, Number of working hours: 100.

Receptionist -> Name: Sam, Address: 8426 Proctor St., Phone: (301) 936-4987, SSN: 365-07-9906, Pay Rate: 30.0 $/hr, Number of working hours: 160.

Executive -> Name: Sean, Address: 6200 Seaside Dr., Phone: (361) 956-4787, SSN: 678-16-4701, Pay Rate: 130.0 $/hr, Number of working hours: 160, Bonus: $12,000.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction To Data Mining

Authors: Pang Ning Tan, Michael Steinbach, Vipin Kumar

1st Edition

321321367, 978-0321321367

More Books

Students also viewed these Databases questions

Question

What is a patent? Give an example.

Answered: 1 week ago