Use a one-dimensional array to solve the following problem: A company pays its salespeople on a commission basis. the salespeople receive $200 per week plus 9% of their gross sales for that week. For example, a salesperson who grosses $5000 in sales in a week receives $200 plus 9% of the $5000, or a total of $650. Write an application (using an array of counters) that determines how many of the salespeople earned salaries in each of the following ranges (assume that each salesperson's salary in truncated to an integer amount):
750, 1200, 5000, 7575, 10000, 9250, 12500, 3560, and 4800.
1
Expert's answer
2012-03-22T09:28:51-0400
public class Question7539 { static int[] Salary = {750, 1200, 5000, 7575, 10000, 9250, 12500, 3560, 4800}; public static void main(String[] args) { for(int i=0; i<Salary.length;i++) System.out.println((i+1)+": "+(200+0.09*Salary[i])+"$"); } }
Numbers and figures are an essential part of our world, necessary for almost everything we do every day. As important…
APPROVED BY CLIENTS
"assignmentexpert.com" is professional group of people in Math subjects! They did assignments in very high level of mathematical modelling in the best quality. Thanks a lot
Comments
Leave a comment