Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

3. Complete the following program to determine the raise and new salary for an employee by adding if else statements to compute the raise. The

image text in transcribed

3. Complete the following program to determine the raise and new salary for an employee by adding if else statements to compute the raise. The input to the program includes the current annual salary for the employee and a number indicating the performance rating (1-excellent, 2=good, and 3 poor An employee with a rating of I will receive a 6% raise, an employee with a rating of 2 will receive a 4% raise, and one with a rating of 3 will receive a 1.5% raise 11 Salary.java 1 Computes the raise and new salary for an employee mport java.util1.Scan public class Salary public static void main (String[] args) double currentSalary; II current annual salary double rating; double raise // performance rating / / dollar amount of the raise Scanner scan - new Scanner (System.in); // Get the current salary and performance rating System.out.print "Enter the current salary:"): currentSalaryscan.nextDouble () System.out.print ("Enter the performance rating: ") ratingscan.nextDouble ) /7 Compute the raiseUse if . .. else // Print the results System.out.println ("Amount of your raise: $" raise) System.out.println ("Your new salary: $" + currentSalary + raise)

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

PC Magazine Guide To Client Server Databases

Authors: Joe Salemi

1st Edition

156276070X, 978-1562760700

More Books

Students also viewed these Databases questions

Question

=+Where does the focus of labor relations lie? Is it collective

Answered: 1 week ago

Question

=+With whom does the firm have to negotiate?

Answered: 1 week ago