Find the rotation point of a rotated sorted array, then do it again when the array has duplicates.
Binary search for the rotation point by comparing the middle element with the right end. If it is larger, the break lies to the right; otherwise it is at mid or before it. That is O(log n). With duplicates an equal comparison says nothing, so you drop the right end, and the worst case becomes O(n).