Force the sub classes

You have created an abstract class and you want to force its sub classes to implement a particular method.

What should you do to enforce this in C#?

  1. Declare the class as virtual
  2. Declare the class as abstract
  3. Add the virtual keyword to the method
  4. Add the abstract keyword to the method

Related Posts