public void AddItem(string name, string description, bool veggie, double price) { var menuItem = new MenuItem(name, description, veggie, price); if (_numberOfItems >= MaxItem) Console.WriteLine("Menu is full."); else { _menuItems[_numberOfItems] = menuItem; _numberOfItems++; } }
public void AddItem(string name, string description, bool veggie, double price) { var menuItem = new MenuItem(name, description, veggie, price); _menuItems.Add(menuItem); }