Binary search with rotated sorted array tests invariant maintenance — common in circular buffer lookups.
Enable JavaScript for the full StreamPrep guide.