Adding max subarray algorithm with n*log(n) time, divide and conquer approach