ITEC 120 LAB 12 Back to Lab index page

Download Salary.java and complete the program to determine the raise and new salary for an employee by adding if 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 (an integer 1 to 10).

An employee with a rating of 10 will receive a 7% raise,
An employee with a rating of 6, 7, 8, or 9 will receive a 6% raise.
An employee with a rating of 2, 3, 4, or 5 will receive a 3% raise.
An employee with a rating of 1 will receive no raise.

Sample 1

Program displays: Enter the current salary:
User enters: 42000
Program displays: Enter the performance rating (1 to 10):
User enters: 8
 
Current Salary:   $42,000.00
Amount of raise:  $2,520.00
New salary:       $44,520.00