Pergunta de entrevista da empresa IBM

Given an array of integers, return the maximum sum of a non-empty subarray.