Write find_min(nums: list[int]) -> int.
nums is a strictly increasing list of distinct values that has been rotated by an unknown amount (possibly 0): a prefix was moved to the end, e.g. [2, 5, 7, 9, 10] → [9, 10, 2, 5, 7]. Return the smallest value.
Example: [9, 10, 2, 5, 7] gives 2; [2, 5, 7, 9, 10] gives 2; [8] gives 8.
Constraints: 1 <= len(nums) <= 10^6, called many times on the same list.
Must be O(log n); min(nums) or any scan fails the performance test.
Show hint
compare the middle element with the last element of the current range. That tells you which side of mid the drop (and so the minimum) is on.