You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
explanation: "For List?\u0020super\u0020Grandparent> you can add Grandparent or any subclass. For List?\u0020extends\u0020Child> you cannot add anything except null. The return type of get() cannot be assumed without casting, so assignments to specific types other than Object are compilation errors. Option 0 compiles fully; the others do not."
610
+
explanation: "For List<? super Grandparent> you can add Grandparent or any subclass. For List<? extends Child> you cannot add anything except null. The return type of get() cannot be assumed without casting, so assignments to specific types other than Object are compilation errors. Option 0 compiles fully; the others do not."
611
611
},
612
612
{
613
613
question: "Which sequence prints in a for-loop with initialization side-effect?",
@@ -681,25 +681,23 @@ <h2>Quiz Complete!</h2>
681
681
explanation: "In bottom-up migration, you begin by converting the module with the fewest dependencies into a named module. Other JARs stay on the classpath initially. This avoids breaking the build and allows gradual migration."
682
682
},
683
683
{
684
-
question: "Which substring is extracted from a text block with escaped newline?",
684
+
question: "Which substring is extracted from this short text block?",
685
685
code: "public class Family {\n"+
686
-
" public static void main(String[] args) {\n"+
687
-
" String familyMessage = \"\"\"\n"+
688
-
" Hello! You inherited a fortune \\\n"+
689
-
" from your grandma!\n"+
690
-
" \"\"\";\n"+
691
-
" String part = familyMessage.substring(7, 15);\n"+
0 commit comments