C#C
C#2y ago
js

object reference not set to an instance of object error

int selection = ConsoleHelpers.GetIntegerInRange(1, count10 - 1, "Please select the item to add to order.");

//var pizzas2 = FoodMenu.pizzas.ToArray();

//var burgers2 = FoodMenu.burgers.ToArray();

int count = 0;

foreach (var pizza2 in FoodMenu.pizzas)
{
    selectionItems[count] = pizza2.ToString();
    count++;
}
image.png
Was this page helpful?