kiaraahquin9491 kiaraahquin9491
  • 02-09-2019
  • Computers and Technology
contestada

. What is the output of this code sequence?

for ( int i = 5; i >= 0; i-- )

System.out.print( i + " " );

System.out.println( );

Respuesta :

NanaDwumor
NanaDwumor NanaDwumor
  • 02-09-2019

Answer:

5

4

3

2

1

0

Explanation:

The boolean expression is true from i=5 to i=0. This makes it 6 times.

The System.out.print will leave cursor on same line after printing. However System.out.println() will print a blank space and move to next line. This makes output to be arranged vertically.

Answer Link

Otras preguntas

Which is a similarity between alcohol fermentation and aerobic respiration?
Email used a total of 7 1half
scientific notation must have how many non zero digits to the left of the decimal point
Your firm has net income of $198 on total sales of $1,200. costs are $715 and depreciation is $145. the tax rate is 34%. the firm does not have interest expense
What did the 13th amendment do? a. none of these.b. it ended slavery in the entire united states.c. it ended slavery in only the south.d. it passed congress nea
When asked to recall the one or two most important events over the last half century, older adults tend to name events that occurred when they were in their?
Which phrase in this passage best helps build tension in the play?
Which of the following statements is true about the colonists' perspectives of British taxes? Select one: a. The colonists did not believe that the British ha
How did nicknames become surnames?
The step of the writing process that involves organizing your thoughts is A. webbing. B. planning. C. brainstorming. D. prewriting