Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write a program that displays a message, asks a user to enter the number of hours worked in one week, and the base hourly rate

image text in transcribed
Write a program that displays a message, asks a user to enter the number of hours worked in one week, and the base hourly rate in dollars. The program then computes the weekly gross pay for the user or produces an error message if erroneous data was inputted. An example of an erroneous data is when the user enter strings instead of numbers. It should be noted that (1) the employee is paid 1.5 times the base hourly rate for hours worked above 40 hours but below or equal 60 hours, (2) the employee is paid 2 times the base hourly rate for hours worked above 60 hours Example output: Four Reals Incorporated Weekly Gross Pay Calculator Enter number of hours worked: 45 Enter your base hourly rate: 10.75 Your weekly gross pay is 510.625 dollars

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Marketing Database Analytics

Authors: Andrew D. Banasiewicz

1st Edition

0415657881, 978-0415657884

More Books

Students also viewed these Databases questions