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
ehidna [41]
2 years ago
8

Write an application named SumInts that allows the user to enter any number of integers continuously until the user enters 999.

Display the sum of the values entered, not including 999.
Computers and Technology
1 answer:
Nana76 [90]2 years ago
4 0

Answer:

import java.util.Scanner;

public class num10 {

   public static void main(String[] args) {

       Scanner in = new Scanner(System.in);

       System.out.println("Enter the numbers to add up. enter 999 to stop");

       int num = in.nextInt();

       int sum = 0;

       while (num!=999){

           sum = sum+num;

           System.out.println("Enter the next number");

           num = in.nextInt();

       }

       System.out.println("The sum is: "+sum);

   }

}

Explanation:

The application is implemented in Java

A while loop is used to continously prompt user for inputs. The condition of the while loop is  while (num!=999)

When the number 999 is entered, it displays the sum which is initialized to 0

You might be interested in
How do I modify objects in power point 2016 for an assignment
ivolga24 [154]

Answer:

PowerPoint gives you pretty good editing control over shapes you insert into a presentation. ...

Once you've selected your shape, you'll notice a new “Shape Format” tab appear. ...

Advertisement. ...

A drop-down menu will appear. ...

Now, to change the shape, click and drag the black edit points to the desired location.

3 0
3 years ago
When a hardware or software interrupt occurs, the CPU calls________
Alja [10]

Answer:

Operating system

Explanation:

An interrupt is the signal sent to the processor that interrupts the current process. It may be generated by a hardware device or a software program.With each interrupt the CPU hardware does exactly the same thing, which is what enables operating systems to take control of the current user operation.

5 0
2 years ago
Which term refers to the science that specifies the design and arrangement of items you use so you interact with the items effic
sashaice [31]

Answer:

the ergonomics To prevent a laptop from being stolen, you can use a surge protector. False; To prevent laptops from being stolen, you can use a cable lock. What is a digital certificate?

6 0
2 years ago
Wendell notices that the company's top executives share a belief that managers are directly responsible for the organization's s
Debora [2.8K]
This belief reflects an omnipotent view of management.
8 0
2 years ago
Designing, producing, exhibiting, performing, writing, and publishing multimedia content including visual and performing arts an
loris [4]
<span>arts, audio-video technology & communications</span>
7 0
2 years ago
Other questions:
  • 2. a. Write pseudocode for a divide-and-conquer algorithm for finding valuesof both the largest and smallest elements in an arra
    11·1 answer
  • ANSWER THIS CORRECTLY FOR BRAINLIEST
    13·2 answers
  • Select the correct answer.
    10·2 answers
  • Brake fluid should be checked __________.
    8·2 answers
  • When a chart is selected, numerous customization options can be found on which Chart Tools tabs?
    11·2 answers
  • Please answer soon
    8·1 answer
  • A school has an intranet for the staff and students to use. Some of the files stored on the intranet are confidential. Give two
    15·1 answer
  • Which of the following parameters is optional sample(a,b,c,d=7
    9·1 answer
  • HW2.24. Statement: Area of a Triangle The area of a triangle can be computed by knowing the base and height of the triangle usin
    11·1 answer
  • Set of general format used to write program in any programming language?​
    10·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!