Question: C++ problem for class yes i know there is one posted for this question but I need it done in a little different from that
C++ problem for class yes i know there is one posted for this question but I need it done in a little different from that one
Programming Assignment: Employees Write a C++ program that performs the following: 1. Asks the user to enter the number of employees in a particular company. 2. Create a dynamic array called namesPtr whose size equals the number of employees. 3. Asks the user to enter the name of each employee. Read each name and store the name in the namesPtr array. Use a for loop to accomplish this. 4. Create a dynamic array named payRatePtr whose size equals the number of employees. 5. Asks the user to enter the pay rate for each employee. Read each pay rate and store the pay rate in the payRatePtr array. 6. Create a dynamic array named hoursWorkedPtr whose size equals the number of employees. 7. Asks the user to enter the hours worked for each employee. Read the number of hours worked for each employee and store this value in the hoursWorkedPtr array. 8. Create a dynamic array named totalPayPtr whose size equals the number of employees. 9. Calculate the total pay for each employee and store the value in the totalPayPtr array. 10. Display output that consists of each employees name and his/her total pay. 11. You may write all of your code in the main function. 12. For this assignment, you do not have to test for valid input. Output A screenshot of a sample run for this program is shown below. Design your program so it looks exactly like the one shown in the screenshot. Use two fixed-point decimal places for all numerical output. Use the setw manipulator to right-align all numerical output. Use the left manipulator to left-align the employee names. CAUsers\Craig Documents\### MGCCC\C++ (f2f\Chapter 9\Programming Assignments\Employe... Enter the number of employees: 3 Enter employee nane 1: John Smith Enter employee nane 2: Sue Ellers Enter employee nane 3: Ricky Jones Enter the pay, rate for each employee. John Snith: 21.5 Sue Ellers: 20.4 Ricky Jones: 15.5 Enter the hours worked for each enployee. John Smith: 40 Sue Ellers: 38.5 Ricky Jones: 31.5 Nane Total Pay John Snith Sue Ellers Ricky Jones 860.00 285.40 488.25
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
