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
True or False<br><br> The signing of Act 26 made Cyber Harassment of a Child a crime.
Levart [38]
True, online bullying is a crime and can be fined or arrested for it.
3 0
3 years ago
What is the first step in the exchange between a web browser and a database?
bezimeni [28]
<span>The client browser requests a page from a Web server.</span>
3 0
3 years ago
Input two numbers and print their sum products difference division and remainder​
likoan [24]

\tt n1=int(input("Enter\: first\:no:"))

\tt n2=int(input("Enter\: second\:no:"))

\tt sum=n1+n2

\tt diff=n1-n2

\tt pdt=n1*n2

\tt div=n1//n2

\tt rem=n1\%n2

\tt print("Sum=",sum)

\tt print("Difference=",diff)

\tt print("Product=",pdt)

\tt print ("Division=",div)

\tt print("Remainder=",rem)

Output:-

Enter first no:4

Enter second no:3

Sum=7

Difference=1

Product=12

Division=1

Remainder=1

7 0
3 years ago
Any fact or set of facts, such as the words in a letter to a friend or the notes in a song, can become computer ____.
Alina [70]

I think the answer is... data

3 0
3 years ago
BOTH QUESTIONS ONLY FILL IN C++ CODEWrite a copy constructor for CarCounter that assigns origCarCounter.carCount to the construc
Alborosie

Answer:

im lost tell me a question then ill answer

Explanation:

4 0
3 years ago
Other questions:
  • You can access decorative underlines and change their color through the ____ drop-down.
    8·1 answer
  • Whenever I go onto Google Chrome, the words are in Spanish! How can I make the words be back in English again? Please let me kno
    7·1 answer
  • Convert (35.125)10 to binary
    9·1 answer
  • You have added a table to your web page consisting of two columns and five rows, including the header row. in the first header c
    13·1 answer
  • Which domain indicates that a website is sponsored by a university or college?
    12·1 answer
  • When would you use the AutoFit to Contents option?
    15·1 answer
  • O Why was the Internet originally constructed? Oto enable researchers to communicate
    6·2 answers
  • The Arizona Department of Transportation has offices throughout the state. State documents are stored on a large server in a cen
    5·2 answers
  • Multi-part question:
    13·1 answer
  • HELP THIS IS SO DIFFICULT
    10·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!