static void Main(string[] args) { Garland garland1 = new ColoredLamp(); garland1.CurrentState(); Garland garland2 = new OrdinaryLamp(); garland2.CurrentState(); }
public override void CurrentState() { Console.WriteLine("How many lamps in the colored garland"); Garland colorednumber = new ColoredLamp(); ColoredCount = colorednumber.CheckNumber(); Console.WriteLine("Count of lamps is" + ColoredCount); List <ColoredLamp> ColoredLampList = new List <ColoredLamp> // Populate List { new ColoredLamp { ID = 1, Color = "a", State = "a" } }; }