protected internal static void CheckIfDoctorPresent(Clinic clinic) { Console.WriteLine(" 1. Enter Doctor's ID \t 2. Select Doctor from the Doctors List"); Console.Write(" Choice: "); int number = Convert.ToInt32(Console.ReadLine()); if (number == 1) { Console.Write(" Doctor's ID: "); int ID = Convert.ToInt32(Console.ReadLine()); clinic.CheckIfDoctorPresent(ID); } if (number == 2) { Console.WriteLine(); foreach (var doctor in clinic.doctors) { Console.WriteLine(" " + doctor.ID + ". " + doctor.Name + " " + doctor.Specialty); } Console.Write(" Number: "); int ID = Convert.ToInt32(Console.ReadLine()); clinic.CheckIfDoctorPresent(ID); } }