← All problemsSign in

Freshers Party

You're organising fresher's party today. You're expecting 'n' freshers and you've already arranged 'm' beer cans. You want to distribute all the beers among your juniors in such a way that each fresher receives the same number of beer cans. Note you cannot divide a beer can into halves. Find the minimum number of additional beer cans you must buy so that each fresher receives same number of beer c

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