public static void Main() { Chef cooker = new Chef(); Potato potato = new Potato(); if (potato != null && potato.IsPeeled && potato.IsRotten) { cooker.Cook(potato); } }
static void Main(string[] args) { IVegetable carrot = new Carrot(); IVegetable patato = new Patato(); IVegetable paper = new Paper(); IVegetable vegetables = new Vegetables(); IAppearance bowl = new Bowl(); IAppearance steamer = new Steamer(); Chef chef = new Chef(); chef.Wash(); chef.Cut(); chef.Prepare(bowl); chef.Cook(steamer); chef.Serve(); }
/// <summary> /// The entry point of the application. /// </summary> public static void Main() { Chef gordonRamsey = new Chef(); Vegetable potato = new Potato(true); Vegetable carrot = new Carrot(true, false, false); gordonRamsey.Peel(potato); gordonRamsey.Peel(carrot); gordonRamsey.Cut(carrot); gordonRamsey.PutInBowl(potato); gordonRamsey.PutInBowl(carrot); foreach (Vegetable vegetable in gordonRamsey.VegitablesInBowl) { Console.WriteLine(vegetable.ToString()); Console.WriteLine(); } }
/// <summary> /// The entry point of the application. /// </summary> public static void Main() { Chef cook = new Chef(); Vegetable potato = new Potato(true, false, false); if (potato != null && potato.IsFresh) { if (!potato.IsPeeled) { cook.Peel(potato); } cook.Cut(potato); cook.PutInBowl(potato); } foreach (Vegetable vegetable in cook.VegitablesInBowl) { Console.WriteLine(vegetable.ToString()); Console.WriteLine("--------------------------------------------------"); } }
public static void Main() { var chef = new Chef(); var bowl = chef.Cook(); }
static void Main() { var chef = new Chef(); chef.Cook(); }