Aug 6, 2022
maxSum and tempSum are 0. Therefor, since maxSum is still 0 after the first for loop, you're just resetting it. Therefor, you don't need to reassign tempSum or the first for loop.
maxSum and tempSum are 0. Therefor, since maxSum is still 0 after the first for loop, you're just resetting it. Therefor, you don't need to reassign tempSum or the first for loop.