Pergunta de entrevista da empresa Tiger Analytics

Coding question: Find the subarray with the maximum sum