Question
Write the code for the application that does the following: a. generates random sales amount in the range [0, 10000] for 10 salespersons and stores
Write the code for the application that does the following: a. generates random sales amount in the range [0, 10000] for 10 salespersons and stores it in an array of doubles. See the Implementation Details below for information about how to generate random numbers in Java. Note that you are generating integer random values but storing it in an array of doubles.
b. determines the commission rate for the salespersons according to the following scheme and store it in an array of doubles: Sales Amount Commission Rate < 1000 5% >= 1000 but < 5000 10% >=5000 15%
c. calculate the commission earned by the salespersons and store it in an array of doubles.
d. displays the sales amount, commission rate, and commission earned of the salespersons on the screen in the same format as shown in the sample output below.
e. Calculates the maximum value in array storing the sales amount and display in the format shown in the sample output below.
f. Calculates the maximum value in array storing the commissions earned and display in the format shown in the sample output below.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started