Exemplo n.º 1
0
        public int BagsOfIcePurchased(int bagsOfIceNeeded)
        {
            Ice ice = new Ice();

            checkOutBagsOfIce = ice.GetCost() * bagsOfIceNeeded;
            return(checkOutBagsOfIce);
        }
Exemplo n.º 2
0
 public void AddIce(int NumberOfIceCubesNeeded)
 {
     for (int i = 0; i < NumberOfIceCubesNeeded; i++)
     {
         Ice ice = new Ice();
         this.ice.Add(ice);
     }
     Console.WriteLine("You currently have {0} ice cubes.\n\n", ice.Count);
 }