![]() Before calculating the raise, the member function should verify that the raise percentage is greater than or equal to zero. The member function should calculate an employee objects new salary, based on a raise percentage provided by the program using the object. The other member function should allow the program to view the contents of the employee name data member.ģ) Add another member function to the Employeeclass. One member function should allow any program using an employee object to view the contents of the salary data member. The class contains two member functions: the constructor and a function that allows a program to assign values to the data members.Ģ) Add two member functions to the Employee class. 1) Write the class definition for a class named Employee with name and salary as employee objects.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |