Inscrivez-vous ou connectez-vous pour rejoindre votre communauté professionnelle.
we can use only one abstract class at a time but multiple interface can be created
To choose Abstract class : to maintain the common behaviour (acquired by base/ abstract class) into the child classes which implements the abstract class.
i will show the code example
public abstract class Employee{
public virtul string FullNamePrint()
{ return "Awais Shabir";
}
}
// Interface Example
Public Interface IEmployee
{string FullNamePrint();
}
if you are using multi inheritance then used interface because interface supports multi inheritance