Find Minimum in Rotated Sorted Array
题目:
Suppose a sorted array is rotated at some pivot unknown to you beforehand.
(i.e., 0 1 2 4 5 6 7 might become 4 5 6 7 0 1 2).
Find the minimum element.
分析:
Finde minimum比search target简单的多,因为分类的时候就2种情况。A[mid]在上面和A[mid]在下面。
解法:
Last updated