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

What type of blood do reptiles and amphibians have? If it depends on species please right them down.
what is the answer of this?
plz help!!! 30. What was the general migration route? 31. What city were Visigoths centered? 32. What city did Vandals emigrate? 33. What is the primary area
is √3/16 a rational or irrational number
what is the answer to subtract the product of 5 and 8 from 50
should society eliminate/remove threats any means necessary? please help me i need to write 3 paragraph on this its hw i really appreciate it thank you guys
What does rodriguez mean by comedy and tragedy of mexico and california?
Mark planning a trip to see his grandmother He will travel for three days. He plans to travel 1,390 miles, and his car gets 25 miles to a gallon of gasoline. He
students and senior citizens pay $2.00 everyone else pays $3.50.Is this a run on, comma splice or fragment?
What is the limit of the absolute value of (x-2) divided by (x-2) as x approaches 2-