WorkSpan Interview Question

Insert a number into a sorted array. In log(n) time complexity.