Sam owns an auto repair shop and has several employees he


Boolean Expressions and Relational Operators

Payroll

Sam owns an auto repair shop and has several employees. He needs to write a simple payroll program. If an employee works over 40 hours in a week, he gets paid 1.5 times their regular hourly pay rate for all hours over 40.

Input:                                                                                                                   

Hours worked

Hourly rate                                                                                        

Calculate

If the employee worked more than 40 hours

Calculate and display the gross pay with overtime           

Else

Calculate and display the gross pay                                                                        

Output: See examples: (input shown in bold)

Enter the number of hours worked: 40

Enter the hourly pay rate: 20

The gross pay is $800.00

Enter the number of hours worked: 50

Enter the hourly pay rate: 20

The gross pay is $1,100.00

Request for Solution File

Ask an Expert for Answer!!
Other Subject: Sam owns an auto repair shop and has several employees he
Reference No:- TGS0607567

Expected delivery within 24 Hours