63. Minimum in Rotated Array
Medium
A strictly increasing array of distinct values was circularly rotated some number of times. Return the minimum value. For example, [12, 15, 2, 5, 8] is a rotation of [2, 5, 8, 12, 15].
Example 1
Input: numeros = [12,15,2,5,8]
Output: 2
Example 2
Input: numeros = [1,3,5,7]
Output: 1
Constraints
- 1 <= numeros.length <= 10000
- Os valores são distintos
- O array é uma rotação de uma sequência crescente
Binary searchArrays
Saved in this browser
Caso 1
numeros =
[12,15,2,5,8]
Expected =
2
Caso 2
numeros =
[1,3,5,7]
Expected =
1
Run checks these 2 cases. Submit runs all 7, including hidden ones.