Question: In java language, Process sales information for each of the salesperson in a firm.Ask the user to enter the number of salespeople.Store the name of

In java language,

Process sales information for each of the salesperson in a firm.Ask the user to enter the number of salespeople.Store the name of each salesperson and the amount of sales in two parallel arrays. Allow to continue only if the user inputs positive number for sales. Use continuous loop. Calculate commission for each salesperson in dollars and store it in another array based on the following.

-Less than $2000, 5% commission

-more than $2000 and less than $5000, 10% commission

-more than $5000, 20% commission

Write a method for each of the following:

-to input and return the number of salesperson

-to gather the required input data.

-to calculate the commission array. -to calculate and return total sales for the firm. Totals sales does not include the commission. -to calculate and return average sales for the firm. The average sales value does not include the commission.

-to calculate and return the total commission for the firm.

-Write a method to display the salesperson's name and amount of sales and the amount of commission for all salesperson in a tabular format. -Write a method that accepts the name of a salesperson as its parameter and returns the amount of commission for the given salesperson. If the given name does not exist, issue an error message.

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!