Question: What is the result of executing the following code snippet? A. 1- B. 1-2- C. 2- D. 3- E. 4- F. None of the above.
What is the result of executing the following code snippet?

A. 1-
B. 1-2-
C. 2-
D. 3-
E. 4-
F. None of the above.
final var GOOD = 100; var score = 10; switch (score) { default: 1: System.out.print("1-"); -1: System.out.print("2-"); break; 4,5 System.out.print("3-"); 6: System.out.print("4-"); 9: System.out.print("5-"); }
Step by Step Solution
3.43 Rating (150 Votes )
There are 3 Steps involved in it
The code snippet youve provided is written in Java and uses the switch statement to control the flow ... View full answer
Get step-by-step solutions from verified subject matter experts
