A reference to a subclass object can be assigned to a superclass variable
A) only if neither the subclass nor the superclass is generic
B) only if at most one of the subclass and superclass is generic
C) only if the subclass is not generic
D) with no restrictions on the genericity of the subclass or superclass
Correct Answer:
Verified
Q19: The Java notation MyClass< Student > means
Q20: Look at the following method header:
Void displayPoint(Point<
Q21: The code fragment
Class MySArrayList extends ArrayList< String
Q22: Erasure is the process of
A) removing references
Q23: When a generic method is called,
A) the
Q25: A type parameter can be constrained
A) with
Q26: The notation < E implements Comparable< E
Q27: Exceptions of a generic type
A) may have
Q28: The notation < E extends Comparable< E
Q29: Let Point< T > be a generic
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents