Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Problem B: Making Decisions Determine an employees gross pay using the number of hours worked and the hourly pay rate. The user will enter the

Problem B: Making Decisions

Determine an employees gross pay using the number of hours worked and the hourly pay rate. The user will enter the hourly rate of pay and the number of whole hours worked. If the number of hours worked is greater than 40, then the hourly rate of pay is increased to 1.5 times the regular rate of pay for those hours above 40.

Program Requirements:

The program should:

Prompt the user for the hourly rate (double) and the number of whole hours worked (integer)

Use output manipulators to format the output as seen below

Make use of constant variables rather than literals within your program

Sample OUTPUT:

Enter your hourly rate of pay: xx.xx

Enter the number of hours worked: x

Hours worked = x

Base pay = $xxx.xx

Overtime pay = $xxx.xx

Gross pay = $xxx.xx

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

How To Build A Million Dollar Database

Authors: Michelle Bergquist

1st Edition

0615246842, 978-0615246840

More Books

Students also viewed these Databases questions

Question

LO2 Identify components of workflow analysis.

Answered: 1 week ago