Bird
0
0

Which of the following is NOT an example of compile-time polymorphism in Java?

easy📝 Conceptual Q2 of 15
Java - Polymorphism

Which of the following is NOT an example of compile-time polymorphism in Java?

AMethod overriding
BConstructor overloading
CMethod overloading
DOperator overloading (using '+' for strings)
Step-by-Step Solution
Solution:
  1. Step 1: Identify compile-time polymorphism examples

    Method and constructor overloading are resolved at compile time.
  2. Step 2: Check method overriding

    Method overriding is resolved at runtime, so it is runtime polymorphism.
  3. Final Answer:

    Method overriding -> Option A
  4. Quick Check:

    Not compile-time polymorphism = Method overriding [OK]
Quick Trick: Overriding is runtime, overloading is compile-time [OK]
Common Mistakes:
  • Confusing overriding with overloading
  • Assuming operator '+' overloading is user-defined
  • Ignoring constructor overloading as polymorphism

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Java Quizzes