SCJP 1.6版考題 201
出自 陳富國維基館
Given:
1. import java.util.*;
2. class A{}
3. class B extends A{}
4. public class Test{
5. public static void main(Strang[] args){
6. List<A> listA = new LinkedList<A>();
7. List listB = new LinkedList<B>();
8. List<Obect> listO = new LinkedList<Obect>();
9. //insert code here
10. }
11. public static void m1(List<? extends A> list){}
12. public static void m2(List<A> list){}
Place a result onto each method call to indicate
what would happen if the method call were inserted at line 9. Note: Results can be used more than once.
| ||||||||||||||||||||

