can you please tell whats wrong in my code.
Please tell whats wrong in my code
@7nishit Check the constraints in the question:
Constraints
1 <= N <= 100000
1 <= t <= 20
-100000000 <= A[i] <= 100000000
Number of elements in the array can go upto 100000 but you have restricted your array size to 1000. Also since cumulative sum can reach a value greater that 10^9…use long long int in place of int.