← All problemsSign in

Birbal and his Ledger

Once upon a time, Birbal was walking along the road and saw a ledger. While looking at the ledger he finds a unique pattern with numbers. Birbal has N numbers and he finds and there is always a sub-array (continuous subset) of numbers whose sum is divisible by N. To test his hypothesis, he comes up with T (Test Cases) sets of N integers and tries to find smallest sub-array whose sum is divisible b

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