VisualizeCode.Dyev
Runner ready

Easy · Sorted Array

Binary Search

Narrow a sorted range with low, mid, and high pointers.

Reference test case

Input: [2, 7, 11, 15], target = 9
Expected output: [0, 1]