public static void RemoveItem(ref RestaurantManager restaurantManager) { Console.WriteLine("Enter the number you want to delete:"); string removeStr = Console.ReadLine(); while (string.IsNullOrWhiteSpace(removeStr)) { Console.WriteLine("Error! Enter the number correctly!"); } restaurantManager.RemoveItem(removeStr); }