Deshaw·Machine Learning Engineer·Technical Phone Screen
- Implement a square root function from scratch, without using any math library functions. It should handle edge cases like zero and very large or very small inputs, and stay within a specified precision bound.
- Rearrange an integer array in-place so that all elements at even positions (1-based) are strictly less than all elements at odd positions. Only O(1) extra space allowed.
“Binary search approach felt natural here.”