Bird
0
0

Which C# feature enables runtime polymorphism?

easy🧠 Conceptual Q2 of 15
C Sharp (C#) - Polymorphism and Abstract Classes
Which C# feature enables runtime polymorphism?
AMethod overloading
BAbstract classes only
CVirtual methods and overriding
DStatic methods
Step-by-Step Solution
Solution:
  1. Step 1: Identify features related to polymorphism

    Runtime polymorphism requires methods that can be overridden, which is done using virtual methods and overriding.
  2. Step 2: Exclude other options

    Method overloading is compile-time polymorphism, static methods cannot be overridden, and abstract classes alone don't enable polymorphism without virtual/override.
  3. Final Answer:

    Virtual methods and overriding -> Option C
  4. Quick Check:

    Runtime polymorphism = virtual + override [OK]
Quick Trick: Virtual and override keywords enable runtime polymorphism [OK]
Common Mistakes:
MISTAKES
  • Confusing method overloading with overriding
  • Thinking static methods can be overridden
  • Assuming abstract classes alone enable polymorphism

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More C Sharp (C#) Quizzes