Solve the max sum array problem. Negative sum has to be considered.