public Lemonade RemoveLemonadeBasket(Lemonade lemonadeOutBasket) { Lemonade outLemonade; outLemonade = Lemonades.FirstOrDefault(l => l.Name == lemonadeOutBasket.Name); if (outLemonade != null) { Lemonades.Remove(lemonadeOutBasket); } return(outLemonade); }
public void AddLemonadeBasket(Lemonade lemonadeToBasket) { if (TotalBasket() < MaxItems) { Lemonades.Add(lemonadeToBasket); } else { Console.WriteLine("Basket is full and I couldn't add " + lemonadeToBasket.Name); } }