In this tutorial, I am going to explain you some Interview Questions and Answers on Oops. Oops is mostly asked topics during Interview.


Here I am going to write some Interview Questions and Answers on Oops. Here it is.

Interview Questions

Interview Questions and Answers on Oops- Part 1

Q) How to inherit a child class from a parent class in C#?

A) Place a colon and then the name of the parent class.


class childclass : BaseClass

Q) How to prevent a class from being inherited by another class? If yes then which keyword makes it possible.

A) We can prevent a parent class from being inherited by another class.

Q) Suppose that I want to allow a class to be inherited, but want to prevent the method from being over-ridden. How is it Possible?

A) Mark the class as public and make the method sealed.

Q) Explain abstract class?

A) An abstract class is a class in C# that can’t be instantiated. An abstract class can have both abstract methods and Concrete method. An abstract class work as a blueprint for a class without any implementation.

Q) List the situation when we actually need Abstract Class?

A) Here are the situations when we need Abstract Class:

  •  We should use an abstract class, when we want to move the common functionality of two or more related classes into a base class and when we don’t want to create an object of that base class.
  • When at least one of the methods in the class is abstract.

Q) Explain Interface?

A) Interface in C# is like a Contract that enforces its client (Class) to follow all protocols. This contract ensures that the class will implement all methods, properties, events defined in the interface. The interface contains only the signature, not the implementation the implementation. Since C# does not support multiple inheritances, so Interface is a way to achieve multiple Inheritances in C#. The interface is used to define what to do not how to do. The “how” part is defined by the class that implement the interface.

You can learn more on Interface here.

Q) Is it possible to specify the access modifiers for methods inside the interface?

A) No, since they all must be public, and are therefore public by default.

Q) Is it possible to inherit multiple interfaces?

A) Yes. .NET does support multiple interfaces inheritance.

Q) What’s the difference between an interface and abstract class?

A) Here is the difference:

  • In interface all methods are abstract means there is no implementation whereas in abstract class some method can be concrete.
  • In Interface all methods no access modifiers are allowed whereas an abstract class may have access modifiers.

You can learn more on Abstract Class here.

Q) What is the difference between a Struct and a Class?

A) Here is the difference:

  • Structs are value-type variables and Classes are a reference type.
  • Another difference is that structs can not be inherited whereas classes can be inherited by a class.

Hope this post about Interview Questions and Answers on Oops is useful for you. We will discuss more on it in later sections.

Interview Questions

Thank You



  • Sí, te escucho con la superación del bloqueo de escritor Cathy – ¡es genial escupir nuevas ideas de artículos! Es bueno escuchar que has estado viendo algo de éxito a través de la herramienta. ¡Buena suerte! 🙂

  • Hola Chris,Nadie le dice a los cerdos – ha!!Kyle hizo un video de Jaaxy sobre cómo colocar su video “Cómo construir un sitio web gratuito en línea” y llevarlo al no1 en YouTube a través de la pestaña de competencia de video de Jaxxy.Esto ha desconcertado a bastantes personas, donde está la pestaña de competencia de video. Pero como usas a Jaaxy, deduzco que habrás notado esta pestaña de la competencia. Te enviaré el enlace al video si quieres echarle un vistazo.

  • Oh my goodness! Awesome article dude! Many thanks, However I am experiencing issues with your RSS. I don’t know the reason why I cannot join it. Is there anybody else having similar RSS issues? Anybody who knows the solution will you kindly respond? Thanks!!

  • I love this POTUS. Wish we’d had him the whole time instead of him walking on eggshells around these hateful righties. Better late than never.

  • I simply want to mention I’m new to blogging and site-building and actually liked you’re web page. Probably I’m likely to bookmark your blog . You surely come with really good article content. Thanks for sharing your web site.