Source Code:-
using A=System.Console;
class Item
{
public void Company()
{
A.WriteLine("Item Code=xxx");
}
}
class Fan : Item
{
public void Model()
{
A.WriteLine("Fan Model:Classic");
} }
class Demo
{
static void Main(string[] args)
{
Item item = new Item();
Fan fan = new Fan();
item.Company();
fan.Company();
fan.Model();
A.ReadKey();
}
}
0 Comments