← All problemsSign in

Next Simple Task

Given an array A consisting of N integers with element at position i denoted by A[i]. Find the minimum number of disjoint contiguous subarrays into which original array can be split such that the sum of elements included over all the sub-arrays must be greater than or equal to M. Any element of the original array can be left out and may not be included in one of the disjoint sub-array obtained af

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start