Arrayy
CodeChefOpen on judge ↗
This time your task is simple.Task: Mehta has to find the longest subarray whose sum is greater than equal to zero in a given array of length N. After he finds out the length of longest subarray, he has to report how many subarrays of such maximum length exist that satisfy the mentioned property. Note:Subarray is defined as an array of contiguous numbers in a particular array. Subarray(A,B) has l
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start