Microsoft interview question

sliding window: max sum of array