Question: Weekly Pay Write a program WeeklyPay.c that computes the weekly earned income of hourly workers. The program should ask the user to enter the hourly

 Weekly Pay Write a program WeeklyPay.c that computes the weekly earned

Weekly Pay Write a program WeeklyPay.c that computes the weekly earned income of hourly workers. The program should ask the user to enter the hourly pay rate and the number of hours worked. It should then output the amount earned with two digits after the decimal point. The program should take into consideration overtime pay. Any number of hours worked beyond 40 hours are compensated by 1.5 times the regular hourly pay. The following is a sample run of the program Enter the hourly rate (S): 17.52 Enter the number of hours worked: 43 Weekly earnings (S): 779.64 Update your program so it asks the user if he wants to compute another weekly pay. If the user enters n or N then the program should exit. Otherwise, it should repeat for a new iteration A sample run is as follows Enter the hourly rate (S): 17.52 Enter the number of hours worked: 43 Weekly earnings (S): 779.64 Do you want to compute another pay? Y Enter the hourly rate (S): 10.40 Enter the number of hours worked: 5 ***Weekly earnings (S): 52.00 Do you want to compute another pay? Y Enter the hourly rate (S): 22.50 Enter the number of hours worked: 40 Weekly earnings (): 900.00 Do you want to compute another pay? N

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!