Question: Consider a class Employee with data members: age(an integer), id (an integer) and salary (a float), and their corresponding member functions as follows class Employee


Consider a class Employee with data members: age(an integer), id (an integer) and salary (a float), and their corresponding member functions as follows class Employee private nt age; int id: float salary; public Employee; // default constructor: age-0, id-0, and salary-0 void setAge(int x); /let agex void setldlntx); I/ let id-x void setSalarv(float x); // salary-x int getAge) return age int getId): /return id float getSa) return salary You need to provide the definition of the default constructor and the first three member functions (setAge, setld and setSalary) inside the scope defined by the brackets of class Employeeand other three member functions (getAge, getld, and getSalary) outside the scope defined by the brackets of class Employee, as shown in the following skeleton class Employee Emplovee void setAge (int x) void setId (int x) void setsalary (float x) int Employee::getAge) int Employee::getId) float Employee::getSalary ( )
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
