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
vampirchik [111]
3 years ago
9

Design a for loop that gets 6 integer numbers from a user, accumulates the total of them, then displays the accumulated total to

the user. Just write the code segment to show what is asked, not a complete program. However, declare any variables that you need to use. Use a semicolon (;) at the end of each line of code so I can tell when you use a new line in your code.
Computers and Technology
1 answer:
PSYCHO15rus [73]3 years ago
6 0

Answer:

Explanation:

The following loop code is written in Java and asks the user for the 6 integer numbers as mentioned in the question and sums them up. Finally putting them into a variable named total and printing it out.

       int total = 0;

       for (int x = 0; x < 6; x++) {

           Scanner in = new Scanner(System.in);

           System.out.println("Enter an integer: ");

           total += in.nextInt();

       }

       System.out.println("Your total is: " + total);

You might be interested in
The best way to ensure the accuracy and safety of your accounts is to:
Gekata [30.6K]
Use symbols and a different password for each one

6 0
3 years ago
To whom the script most important
baherus [9]
The scripter as he made the script.
5 0
3 years ago
Which type of network involves buildings in multiple cities connecting to each other?
NeX [460]

Answer:

Power lines

Explanation:

Because their everywhere

4 0
3 years ago
What can be designed to create annoying glitches or destroy data
Katen [24]

I guess the best answer is Virus.

Virus is a malicious computer program that is designed to create annoying glitches or destroy data.

3 0
3 years ago
Read 2 more answers
What is the decimal equivalent of (11000 + 10000)/101?
Arturiano [62]

its answer in binary is 1000 and in decimal is 8.

7 0
3 years ago
Other questions:
  • Emma opened a new document a Microsoft word and typed her assignment. She is now planning to save the documents for the first ti
    11·1 answer
  • Please help i really need to turn this in already
    6·1 answer
  • Pascal's Triangle is a triangular array in which every number represents the
    15·1 answer
  • To remove text from a specific location and keep it to use again, you should select ___
    6·1 answer
  • i need to also do a algorithm where if the total is a even number 10 points are added to the score and if the total is odd then
    11·1 answer
  • What two devices in a computer should be considered "black boxes," and should never be opened due to risks involving charged cap
    13·1 answer
  • Explain any two features of a computer​
    15·1 answer
  • These 2 questions PLEASEEE (:
    14·1 answer
  • Pa answer po thank you​
    7·2 answers
  • Define a python functions that draw a pinwheel using the pinwheel function that has input paramiters that allows you to change t
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!