← All problemsSign in

Distribute Candies

IIIT Allahabad is celebrating its annual Techno-Cultural Fiesta from 1st to 5th October. The Chef has agreed to provide the supply candies for this fest. The Chef has N boxes of candies arranged linearly having some random number of candies in each box . Chef wants to have same number of candies in each box but he can only transfer candies to the next (i+1) th box only. He can remove any number of

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