Infosys interview question

Find the maximum subarray sum(kadane" algo)