Answered step by step
Verified Expert Solution
Question
1 Approved Answer
solve this in c++ with complete detail and comments. Wo. 2 Write a program with three different classes, 'Person', 'SalariedEmployee' and Commission Employee 'Person' should
solve this in c++ with complete detail and comments.
Wo. 2 Write a program with three different classes, 'Person', 'SalariedEmployee' and Commission Employee 'Person' should be base class and "Salaried Employee' as well as 'CommissionEmployee' must be directly derived from it. 'Person has a member function 'Calculate Salary, which in return calls function "Salary which exists in all the classes. Make sure that objects of all classes call their own function of salary Calculate salary for "Salaried Employee' by taking number of months as input and multiply it with their salary which has already been set using appropriate "SetSalary function. Calculate salary for 'Commission Employee' by taking number of hours as input and multiply it with their hourly rate which has already been set using appropriate "SetSalary function. (15 Marks)Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started