Question: Problem 1: Operator Overloading Write a class Employee having following attributes: 1. String name 2. Integer Age 3. Float Salary Over load the appropriate operators

Problem 1: Operator Overloading Write a class Employee having following attributes: 1. String name 2. Integer Age 3. Float Salary Over load the appropriate operators for the following functionality: 1. Input employee object 2. Output employee object 3. Convert the employee object to an integer (that integer should be the half of the employee's salary) Write another class Person having the following attributes: 1. String name 2. Integer Age Convert an object of type Employee to person. You can use assignment operator for this purpose
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
