Question: 011 Create a class called person that contains private variables: ID, name, job, salary, start_Time_ofWork, end_Time_ofWork, and hours of Work. This class will be inherited

011 Create a class called person that contains private variables: ID, name, job, salary, start_Time_ofWork, end_Time_ofWork, and hours of Work. This class will be inherited into two classes: manager class and employee class. Each of these classes contains a member function called getdata() to display the person's information with position and a member function called getAnnualSalary() to display the manager's annual salary with 10% bonus and the employee's annual salary. By following the conditions below: Name variable must be at least 2 characters. 2. Salary variable between 300 - 500. 3. Works hours must be 6 hours. Working hours should be between 8 a.m. and 2 p.m. A main O program should initialized two objects, and then display the information about these two objects. 011 Create a class called person that contains private variables: ID, name, job, salary, start_Time_ofWork, end_Time_ofWork, and hours of Work. This class will be inherited into two classes: manager class and employee class. Each of these classes contains a member function called getdata() to display the person's information with position and a member function called getAnnualSalary() to display the manager's annual salary with 10% bonus and the employee's annual salary. By following the conditions below: Name variable must be at least 2 characters. 2. Salary variable between 300 - 500. 3. Works hours must be 6 hours. Working hours should be between 8 a.m. and 2 p.m. A main O program should initialized two objects, and then display the information about these two objects
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
