Question d’entretien chez Walmart

find an element in a rotated sorted array