Beispiel #1
0
 public WellDone(double currentTemp, Steak steak)
 {
     this.currentTemp = currentTemp;
     this.steak       = steak;
     canEat           = true;
     Initialize();
 }
Beispiel #2
0
 public Rare(double currentTemp, Steak steak)
 {
     this.currentTemp = currentTemp;
     this.steak       = steak;
     canEat           = true; //We can now eat the steak
     Initialize();
 }
        static void Main(string[] args)
        {
            Steak account = new Steak("Shitty tykstegsbøf from Fakta");

            // Apply temperature changes
            account.AddTemp(120);
            account.AddTemp(15);
            account.AddTemp(15);
            account.RemoveTemp(10); //Yes I know cooking doesn't work this way, bear with me.
            account.RemoveTemp(15);
            account.AddTemp(20);
            account.AddTemp(20);
            account.AddTemp(20);

            Console.ReadKey();
        }
Beispiel #4
0
        static void Main(string[] args)
        {
            Steak account = new Steak("T-Bone");

            // Apply temperature changes
            account.AddTemp(120);
            account.AddTemp(15);
            account.AddTemp(15);
            account.RemoveTemp(10);
            account.RemoveTemp(15);
            account.AddTemp(20);
            account.AddTemp(20);
            account.AddTemp(20);

            Console.ReadKey();
        }
Beispiel #5
0
        static void Steak()
        {
            // Let's cook a steak!
            Steak account = new Steak("T-Bone");

            // Apply temperature changes
            account.AddTemp(120);
            account.AddTemp(15);
            account.AddTemp(15);
            account.RemoveTemp(10); //Yes I know cooking doesn't work this way
            account.RemoveTemp(15);
            account.AddTemp(20);
            account.AddTemp(20);
            account.AddTemp(20);
            Console.ReadKey();
        }