What is exactly an empty Sub-array
If you have this array: $[-2,-10,-5]$, and the problem specifies that you should return to it the sum of the maximum subarray whose length is at least $1$, you will return the sum of the subarray $[-2]$, which is $-2$. So far so good?
Now, focus here because this is where you are most probably having trouble:
The problem is now tweaked. The problem now allows you to return to it an empty subarray, which means, you can return to it a subarray that is empty - a subarray that has no elements. Bear with me:
In mathematics, an &quot;empty sum&quot; is a summation where the number of terms is zero. Verify.
Similarly, in computer science, an &quot;empty subarray&quot; is a subarray in which the number of terms is zero. This is just the definition. It's just a subarray whose sum evaluates to zero.
Now, concerning the tweaked version of the problem, what would be better, returning to it $[-2]$ whose sum evaluates to $-2$, or returning the empty subarray $( [ \ \ \ ] )$ whose sum evaluates to $0$?