1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Jlenok [28]
3 years ago
6

Use a one-dimensional array to solve the following problem: A company pays its salespeople on a commission basis. The salespeopl

e receive $200 per week plus 9% of their gross sales for that week. For example, a salesperson who grosses $5,000 in sales in a week receives $200 plus 9% of $5,000, or a total of $650. Write an app (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 is an integer). a) $200–299
b) $300–399
c) $400–499
d) $500–599
e) $600–699
f) $700–799
g) $800–899
h) $900–999
i) $1000 and over
Summarize the results in tabular format.
Computers and Technology
1 answer:
inysia [295]3 years ago
6 0

Answer: Provided in the explanation section

Explanation:

import java.util.Scanner;

public class commission

{

   public static void main(String[] args) {

      Scanner input = new Scanner(System.in);

        int totals[]={0,0,0,0,0,0,0,0,0};          

      int n,sales,i,index;

       double salary;

        System.out.print("how many salesmen do you have? ");                          

      n=input.nextInt();

        for(i=1;i<=n;i++)

           {System.out.print("Salesman "+i+" enter sales: ");

            sales=input.nextInt();

            salary=200+(int)(.09*sales);

               System.out.printf("Salary=$%.2f\n",salary);

            index=(int)salary/100-2;

            if(index>8)

                index=8;

            totals[index]++;

            }

        System.out.println("SUMMARY\nSALES\t\tCOUNT");

        for(i=0;i<8;i++)

           System.out.println("$"+(i*100+200)+"-"+(i*100+299)+"\t"+totals[i]);

        System.out.println("$1000 and over\t"+totals[i]);

       }                                

   }

 

cheers i  hope this helped !!      

You might be interested in
What does SFA software provides tools for
solong [7]
They provide tools for sfa spftware
5 0
3 years ago
Read 2 more answers
Provides images of weather systems, and helps to track storms at different altitudes
olasank [31]
A weather satellite is used to monitor weather systems and the climate of the earth. Weather satellites have two types orbits. They can either have near-polar orbit or geostationary orbit. The former has lower altitudes and covers the complete Earth. The latter, on the other hand, stays put in one spot, and is found in higher altitudes.
6 0
3 years ago
Write a set of pseudocode instructions to feed a pet, using at least five steps?<br><br> Thank you!!
stira [4]
1.) Go get bag of pet food from cabinet

2.) Set the bag on counter

3.) Get pet food dish out of cabinet

4.) Open pet food bag, pour pet food into dish

5.) Close bag, give dish to pet.
4 0
3 years ago
What is computer software?​
Lady_Fox [76]

Answer:

Software is a collection of instructions that tell a computer how to work. This is in contrast to hardware, from which the system is built and actually performs the work.

3 0
2 years ago
Read 2 more answers
______ is the software that blocks a user from being able to access your computer.
antiseptic1488 [7]
The answer is firewall. It is a network security device that observes inbound and outbound network traffic and chooses whether to allow or block specific traffic based on a well-defined set of security rules. Firewalls have been a first line of protection in network security for over 25 years. The firewall present a barrier between measured and secured internal networks that can be trusted and untrusted outside networks, for example the Internet. A firewall can be software, hardware, or even both.
8 0
3 years ago
Other questions:
  • Rori is looking for a way to interact with others while increasing her stamina. Which community resource would be least helpful
    13·1 answer
  • Rate is how fast a screen updates the information being displayed.
    6·2 answers
  • Need 2.5 Code Practice Answers
    14·2 answers
  • When working with arrays, most programming languages perform ________, which means they do not allow programs to use invalid sub
    5·1 answer
  • In Access, it is possible to have _______________ fields, that is, fields that can contain more than one value.
    9·1 answer
  • Which of the following accessories would you use to create a drawing? A. Calculator B. Notepad C. Paint D. WordPad
    14·2 answers
  • Rewritable (write, erase, write again) is known as _______.
    7·1 answer
  • Define Agricultural Era
    14·2 answers
  • What blockchain implementation resulted from bitcoin’s rejection of a recommendation to enhance its scripting language support?
    9·1 answer
  • Select the three concepts of capital outlay.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!