Given:
3. import java.util.*; 4. class Creature { } 5. class Animal extends Creature { } 6. class Pet extends Animal { } 7. public class Main { 8. ArrayList<Animal> go() { 9. // insert code here 10. } 11. }
Which statement inserted independently at line 9 will compile?
Choose all that apply.
B is correct.
A is incorrect because polymorphic assignments don't apply to generic type parameters.
C and D are incorrect because they don't follow basic polymorphism rules.