Question: Create a Java program that solves a real-life calculation problem. Scenario You have just started a sales job. Your pay consists of a base salary

Create a Java program that solves a real-life calculation problem.

Scenario

You have just started a sales job. Your pay consists of a base salary and a commission. The base salary is $5,000 per month. The scheme shown below is used to determine the commission rate.

Sales Amount Commission Rate

--------------------------------------------------------------------

$0.00-$5,000 8%

$5,000.01 - $10,000 10%

$10,000.01- and above 12%

Note that this is a graduated rate, meaning your first $5,000 in sales nets you 8% commission and the next $5,000 you get 10%.

Let's do an example. Say you sold $25,000 in a month. That means you would receive: ($5,000*8%)+($5,000*10%)+($15,000*12%)+$5,000 = ($400) + ($500) + ($1,800) + $5,000 = $7,700.

What about $8,000 in sales? That would be ($5,000 * 8%) + ($3,000 * 10%) + $5,000 = ($400) + ($300) + ($5,000) = $5,700.

Objective

We are going to write a program that performs these calculations and outputs a table of values showing how much money someone will make given an amount of sales that month. You will start with the sales amount $1,000 and increment it by $1,000 up to $20,000 in sales (see the table below for an example output).

You will create a function that looks like the following:

public static double computeIncome(double salesAmount)

Given a sales amount it will calculate the amount of money earned that month. Don't forget to add the base salary of $5,000!

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!