Question: Let's modify this C++ program to pay time-and-a-half for all hours over 40 worked in a week, and add to gross pay calculation. Remember to
Let's modify this C++ program to pay time-and-a-half for all hours over 40 worked in a week, and add to gross pay calculation. Remember to display both the base pay and the overtime pay, before taking out any tax. Display results in standard currency format, with symbols and decimals aligned. HINT: The style of your program matters so.... Indent at least 4 spaces within each block. All statements within a block should be aligned spaced appropriately. gross pay = (hours up to 40 worked * hourly rate) + (hours over 40 worked * 1.5 * hourly rate) SAMPLE RUN: Please enter number of hours worked: 42 Please enter hourly rate: 10 Base pay: $400.00 Overtime pay: $ 30.00 Gross pay: $430.00 Social Security tax: $ 25.00 Net pay: $405.00
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
