Thursday, January 13, 2022

What is interface

interface is just like a class. It is having blueprint of class.


ref:-  https://www.w3schools.com/cs/cs_interface.php

What is abstract class and interface

 abstract classes are fast vs interfaces are slow.

abstract class have single class inheritense vs interface is having multiple class inheritense

abstract keyword for creating abstract class and interface keyword for creating  interface

both(interface and abstract class) can not be instanced.

abstract class is having abstract functions and override is used with function that is having inheritense.


interface:- by default public members

abstract class:- by default  public and private members


reference :- https://www.educba.com/c-sharp-interface-vs-abstract-class/

https://www.geeksforgeeks.org/c-sharp-abstract-classes/