StacySams2271 StacySams2271
  • 02-03-2020
  • Computers and Technology
contestada

What is the output of the following code snippet? int age = 25; if (age > 30) { System.out.println("You are wise!"); } else { System.out.println("You have much to learn!"); }

Respuesta :

ijeggs
ijeggs ijeggs
  • 04-03-2020

Answer:

You have much to learn!

Explanation:

In the question the variable age has been declared and assigned the value of 25.

The if Statement checks if age >30 to output "You are wise!" else it will output "You have too much to learn"

Since age has been assigned the value of 25, we expect the program to execute the else block which is "You have too much to learn"

Answer Link

Otras preguntas

which channel is the most popular one for the evening news A. WANR B. WWCN C. WCLM D. WKOD
How are carbon, hydrogen, and oxygen alike?
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
the cards in a card catalog are filed in what manner? A: by publication B: by subject C: alphabetically D: by call number
what act did the united states government pass in order to be able to move Native American of their lands into the Indian's Territory? A) Native American Act B)
How do you say "Some brown spiders"?
How does the value of the 8 in 589,310 compare to the value of the 8 in 598,301? A. It is 8 times as much B.It is 10 times as much C. It is 80 times as much
How to make a mixed fraction
find the slope of the line that contains (1,6) and (10, -9).
the only Native American who successfully stayed on their land were A) Seminole B) Sauk C) Cherokee D) Fox