Question

Write a function to find the largest sum of contiguous sequence?

Login to Submit

Examples

Input: [-1, -2, 0, 1, 2]
Output: 3
Reason: 0+1+2 is the maximum sum