Sqrt(x) — binary search for the boundary
Search for the first number whose square exceeds x. The integer square root is one less than that boundary.
Try:
← Prev
Next →
▶ Play
Reset
left =
1
mid =
–
right =
1