Question: Need help with this program it needs to be written in C++ and run in visual studio. Also can you out comments explaining what each

Need help with this program it needs to be written in C++ and run in visual studio. Also can you out comments explaining what each line does.

Input: File input is for an unknown number of employees; there are 4 lines of data for each employee. The first line has the employees full name. The second line contains the employees hourly pay rate, which always has a $ sign on its left; there may be other text (characters) before and/or after the pay rate. The third line has the number of hours worked; this number always has a colon (:) followed by a space on its left. Other text may be present as well. The fourth line contains a dollar amount which the employee wants put into a savings account; this value is always preceded by the $ sign. Sample input for two employees is shown below:

Ralph Montgomery

My pay is $12.00 per hour.

I worked: 38.75 hours.

Amount for Savings is $100.00

Mary K. Smith

Pay - $11.50

Hours Worked: 45.5 hours

Save $150

The program calculates total weekly pay; the hourly pay rate is used for hours up to and including 40. Any hours over 40 earn 1.5 times the hourly pay rate. The program also calculates the paycheck amount, which is the pay after the savings amount is deducted (net pay).

Output: Output formatting features are used to produce a table with a column for Employee Name, pay rate, hours worked, total pay, savings, and net pay. The first table row has these headings for each column; each row thereafter has the results for one employee. Dollar amounts display with a $ sign on the left of the column, and two decimal places. The numerical amounts are right-adjusted in the column, so the decimal points line up

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!