Computer Science, asked by reddyvandana147, 10 months ago

c++ program to calculate employee salary using class and object​

Answers

Answered by akm26381
0

Explanation:

Step 1 - Include the required header files (iostream.h, conio.h, and windows.h for colors).

Step 2 - Create a class Employee with the following members.

emp_number, emp_name, basic, da, it, gross_salary, and net_salary as data memebrs

read_emp_details(), find_net_salary(), and display_emp_details() as member functions.

Step 3 - Implement all the member functions with their respective code.

Step 4 - Create a main() method.

Step 5 - Create an array of class object with a specific size and number_of_emp as integer.

Step 6 - Read number_of_emp.

Step 7 - Call the read_emp_details() method through the array of class object from 0 to number_of_emp.

Step 8 - Call the find_net_salary() method through the array of class object from 0 to number_of_emp.

Step 9 - Call the display_emp_details() method through the array of class object from 0 to number_of_emp.Step 10 - returnn 0 to exit form the program execution.

Similar questions