Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Hello, Can you please assist me.... I am writing a Java application that prompts a user for a fist name and a last name, and

Hello,

Can you please assist me.... I am writing a Java application that prompts a user for a fist name and a last name, and then asks if a user is a company's employee. If positive, I have to prompt for an hourly pay rate and hours worked. After that I have to compute the gross pay (hours times rate), withholding tax, and net pay (gross pay minus withholding tax). The withholding tax should be computed as percentage of gross pay based on the following scale.

Gross Pay: Withholding Percentage:

0 to 300.00 8%

300.01 to 400.00 10%

400.01 to 500.00 12%

500.01 and over 15%

Then I have to display the user's name (first and last), hourly rate, hours worked, withholding tax percentage, withholding tax and gross pay.

Then I will have to ask a user if she/he wants to add a medical insurance. If positive, I will have to offer three choice (each of them can be added independently from others) : 1) medical insurance at $50; 2) dental insurance at $25; 3) long term disability at $10. Then I have to deduct the selected insurance(s) from the gross pay. If the deductions exceed the gross pay, display an error message, otherwise display the pay amount to be sent to a user.

When a user is not an employee - display the proper message on that and terminate the application.

I will have to use logical AND and OR operators when designing the logic of the application.

Note: I can also use the JOptionPane input dialog instead of the Scanner class.

Can you please assist me in this assignment. I am truly stuck and am continuously receiving an error.

Thanks in advance!

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

Financial management theory and practice

Authors: Eugene F. Brigham and Michael C. Ehrhardt

12th Edition

978-0030243998, 30243998, 324422695, 978-0324422696

Students also viewed these Programming questions