Microsoft interview question

Maximum subarray sum using Kadane Algorithm