Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ ) The All-Natural Wood Furniture Company has recently hired you to help them convert their manual payroll system to a computer-based system. Write a

C++

) The All-Natural Wood Furniture Company has recently hired you to help them convert their manual payroll system to a computer-based system. Write a program to produce a 1-week payroll report for only one employee to serve as a prototype (model) for the administration to review. Input for the system will be the employees 4-digit ID number, the employees name, hours worked that week, and the employees hourly pay rate. Output should consist of the employees ID number, the employees name, the hours worked that week, the hourly rate, the gross pay, Federal withholding deduction based on an 18% tax rate, State withholding deduction based on a 4.5% tax rate, and net pay. a. Use main( ) as the driver function. Allow the user to run the program as many times as desired. b. Write 5 functions that main( ) calls to accomplish the task: 1. getData( ): Prompts the user for an employees 4-digit ID #, the employees name, the hours worked that week, and hourly pay rate. Criteria for data validation: a. Employee ID must be an integer between 1000 and 9999, inclusive. Do not allow user to enter an ID number out of this range. b. Hours worked must be greater than zero and less than 120. Do not allow user to enter the amount of hours worked outside of this range. c. Hourly Rate must be greater than zero. Do not allow the user to enter a zero or a negative pay rate. 2. computeGrossPay( ): Computes gross pay earned by employee. An employee working more than 40 hours per week is compensated at time-and-a-half for every hour over 40. 3. computeDeductions( ): Computes the Federal and State withholding deductions using the rates listed above. 4. computeNetPay( ): Calculates the net pay for the employee. 5. displayResults( ): Displays the employees ID#, the employees name, the hours worked, the hourly pay rate, gross pay, Federal withholding amount, State withholding amount, and Net Pay.

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

Database Management System MCQs Multiple Choice Questions And Answers

Authors: Arshad Iqbal

1st Edition

1073328554, 978-1073328550

More Books

Students also viewed these Databases questions

Question

In Problems 1-2, determine the values of r and (? 1. 2. 3

Answered: 1 week ago

Question

Where those not participating, encouraged to participate?

Answered: 1 week ago

Question

3. Who would the members be?

Answered: 1 week ago