Largest Subarray With Zero Sum
easy
1. You are given an array(arr) of integers. 2. You have to find the length of the largest subarray with sum 0.
Constraints
1 <= N <= 10^6 1 <= arr[i] <= 10^4
Format
Input
A number N arr1 arr2.. N numbers
Output
A number representing the length of largest subarray with zero sum.
Example
Sample Input
8
15 -2 2 -8 1 7 10 23
Sample Output
5
Question Video