Page 1 of 1

About Question enthuware.ocajp.i.v8.-2.-1313 :

Posted: Mon Jan 11, 2016 11:13 am
by chmelvv
What is the result of executing the following code when the value of i is 5:

Code: Select all

switch (i){     
default:     
case 1:         System.out.println(1);     
case 0:         System.out.println(0);     
case 2:         System.out.println(2);         break;     
case 3:         System.out.println(3); 
}
Right answer is "1 0 2" (the same wrote in explanation), but in test "Nothing will be printed." marked as right answer.

Re: About Question enthuware.ocajp.i.v8.2.1313 :

Posted: Mon Jan 11, 2016 10:30 pm
by admin
Yes, I see that option 1 is indeed marked as the correct answer.
HTH,
Paul.

Re: About Question enthuware.ocajp.i.v8.2.1313 :

Posted: Tue Dec 10, 2024 6:57 pm
by aurelios
edited.

Re: About Question enthuware.ocajp.i.v8.2.1313 :

Posted: Tue Dec 10, 2024 10:17 pm
by admin
Not sure where are you looking but it shows option 1 marked as correct as it always did.see screenshot attached.
Scan 11 Dec 24 · 08·46·08 17338869682461.jpeg
Scan 11 Dec 24 · 08·46·08 17338869682461.jpeg (77.35 KiB) Viewed 2122 times

Re: About Question enthuware.ocajp.i.v8.2.1313 :

Posted: Sat Dec 14, 2024 9:26 am
by aurelios
I apologize for the mistake, you are correct. The software shows the correct answer.