A monitoring system records the CPU load sample (a non-negative integer) for each of n consecutive minutes. Find the length of the longest contiguous window of minutes whose total load sums to EXACTLY a given budget K. If no such window exists, print 0.
Input format
Line 1: two integers n and K.
Line 2: n space-separated non-negative integers, the load samples.
Output format
A single integer: the length of the longest contiguous window summing to exactly K, or 0 if no window sums to exactly K.
Constraints
- 1 ≤ n ≤ 100000
- 0 ≤ load[i] ≤ 1000
- 0 ≤ K ≤ 1000000000