Due at the end of class, Friday, February 27, 2004
The Calculating Salaries Program.
Lily and Larry run L & L Laptops Inc. They employ over 250 workers. In their company there are four categories of workers. The workers are categorized according to what they do and each gets paid according to the categories. The levels of pay for each category are as follows:
| Level | Salary | |
| A | 45,000 | |
| B | 52,000 | |
| C | 67,000 | |
| D | 88,000 |
As well as their regular salary, each person receives a bonus amount each year based upon the years of experience with the company. These amounts are as follows:
|
Years Experience Bonus Chart |
|||||
| Level | 1 - 5 | 6 - 10 | Over 10 | ||
| A | 2,000 | 3,500 | 6,000 | ||
| B | 3,000 | 4,000 | 6,000 | ||
| C | 4,500 | 5,500 | 10,000 | ||
| D | 4,500 | 6,000 | 10,000 | ||
For example, an employee in level C with 7 years of experience would earn $72,500 ($67,000 regular salary + $5,500 bonus).
There is also an exemplary employee award that can provide the employee with an additional 10% of their total salary (base salary + bonus).
Your assignment is to write a program that will input the employee's:
|
|
Pay level (char A, B, C, or D) |
|
|
Years of experience (int) |
|
|
Exemplary employee award status (boolean true or false) |
and calculate their salary. The main method should only contain method calls. Break up your methods up logically so that the program has different methods for input, output, and calculations. It should not all be written in one method.
Evaluation:
Documentation
/4
Handling of
inputs/outputs
/4
Use of
methods
/6
Use of if
statements /8
Correct solution to test
data /8
Total
/30