Here, I created a interface IShow having one method Show(). We have two Class A, B inhrits from Interface IShow. In this Senario, how many way to programmer can show() method.
namespace ConsoleApplication
{
interface IShow
{
void Show();
}
class A : IShow
{
public virtual void Show()
{
Console.WriteLine("Base Class function");
}
public void Show1()
{
Console.WriteLine("Base Class function");
}
}
class B : A
{
public override void Show()
{
Console.WriteLine("Drived Class function");
}


Join the conversation! Your thoughts help the community grow.