static void Main()
 {
     Chef test = new Chef("Some Guy");
     Carrot carrot = new Carrot();
     Potato potato = new Potato();
     test.PrepareVegetable(carrot);
     test.PrepareVegetable(potato);
     test.Cook(potato, carrot);
 }
Пример #2
0
        static void Main()
        {
            Chef chef = new Chef();

            {
                Potato potato = new Potato();

                if (potato == null)
                {
                    throw new ArgumentException();
                }

                if (potato.IsPeeled && !potato.IsRotten)
                {
                    chef.CookByProducts(potato);
                }
            }

            // ....
        }
Пример #3
0
        static void Main()
        {
            Chef chef = new Chef();

            {
                Potato potato = new Potato();

                if (potato == null)
                {
                    throw new ArgumentException();
                }
                
                if (potato.IsPeeled && !potato.IsRotten)
                {
                    chef.CookByProducts(potato);
                }
            }

            // ....
        }
Пример #4
0
        public static void Main()
        {
            // TASK 2

            IPotato potato = new Potato();
            Chef    chef   = new Chef();

            if (potato != null)
            {
                if (!potato.IsRotten && potato.IsPeeled)
                {
                    chef.Cook(potato);
                }
            }

            // -----

            if (IsInColRange() && IsInRowRange() && !IsVisited())
            {
                VisitCell();
            }
        }
Пример #5
0
        public static void Main()
        {
            var chef = new Chef("Andre Tokev");

            chef.Cook();
        }
Пример #6
0
 static void Main(string[] args)
 {
     var chef = new Chef();
     var bowl = chef.Cook();
     Console.WriteLine("Ingredients prepared in the cooking bowl:\n{0}", bowl);
 }