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

por que os vulcões e os terremotos são mais freqüentes em certas regiões do planeta
A weather balloon has a volume of 52.5 liters at a temperature of 295 K. The balloon is released and rises to an altitude where the temperature is 252 K. How do
what's an improper fraction
find the slope of the line that contains (1,6) and (10, -9).
Brody added a fraction to 5/6 to get 31/30. Use the equation a/b + c/d = (ad +bc)/ bd to find the fraction he added
how is aluminium foil able to reduce heat loss through the walls of a house
what years did the cattle drives take place from
by what length is is 0.5 m less than 10.05
6 5/10 as improper fraction
13. (1 pt) Who was Hiram Bingham? A. a Harvard-trained archaeologist who first explored the Maya ruins at Tikal B. a Yale-trained explorer who first discover