# Intermediate programming project 1 | Computer Science homework help

The first programming project involves writing a program that computes the average salary for a collection of employees of different types. This program consists of four classes. The first class is the `Employee` class, which contains the employee’s name and monthly salary, which is specified in whole dollars. It should have two methods:

1. A constructor that allows the name and monthly salary to be initialized.
2. A method named `annualSalary` that returns the salary for a whole year.

The `Employee` class has two subclasses. The first is `Salesman`. It has an additional instance variable that contains the annual sales in whole dollars for that salesman. It should have the same two methods:

1. A constructor that allows the name, monthly salary and annual sales to be initialized.
2. An overridden method `annualSalary` that returns the salary for a whole year. The salary for a salesman consists of the base salary computed from the monthly salary plus a commission. The commission is computed as 2% of that salesman’s annual sales. The maximum commission a salesman can earn is \$20,000.

The second subclass is `Executive`. It has an additional instance variable that reflects the current stock price. It should have the same two methods:

1. A constructor that allows the name, monthly salary and stock price to be initialized.
2. An overridden method `annualSalary` that returns the salary for a whole year. The salary for an executive consists of the base salary computed from the monthly salary plus a bonus. The bonus is \$30,000 if the current stock price is greater than \$50 and nothing otherwise.

Finally there should be a fourth class than contains the main method. It should create an array of objects of type `Employee` and initialize them to a mixture of different kinds of employees. It should then compute and display the average salary for all employees.

Be sure to follow good programming style, which means making all instance variable private and naming all constants. Furthermore you must select enough different kinds of employees to completely test the program.

In the general discussion area, you will find a topic that explains the submission requirements and grading rubric that applies to all projects.

## Calculate the price of your order

550 words
We'll send you the first draft for approval by September 11, 2018 at 10:52 AM
Total price:
\$26
The price is based on these factors:
Number of pages
Urgency
Basic features
• Free title page and bibliography
• Unlimited revisions
• Plagiarism-free guarantee
• Money-back guarantee
On-demand options
• Writer’s samples
• Part-by-part delivery
• Overnight delivery
• Copies of used sources
Paper format
• 275 words per page
• 12 pt Arial/Times New Roman
• Double line spacing
• Any citation style (APA, MLA, Chicago/Turabian, Harvard)

# Our guarantees

Delivering a high-quality product at a reasonable price is not enough anymore.
That’s why we have developed 5 beneficial guarantees that will make your experience with our service enjoyable, easy, and safe.

### Money-back guarantee

You have to be 100% sure of the quality of your product to give a money-back guarantee. This describes us perfectly. Make sure that this guarantee is totally transparent.

### Zero-plagiarism guarantee

Each paper is composed from scratch, according to your instructions. It is then checked by our plagiarism-detection software. There is no gap where plagiarism could squeeze in.

### Free-revision policy

Thanks to our free revisions, there is no way for you to be unsatisfied. We will work on your paper until you are completely happy with the result.