Calculate square root for a number using binary search. Failed to handle integer square overflow issue when a large integer is given in first submit.