The Bottles
CodeChefOpen on judge ↗
Drink and Code is over :-( and there is a huge pile of empty bottles left after the contest, they are all of different sizes. One of the organisers Jai is a smart guy. To clean up all the empty bottles he takes the help of a little trick. He picks a small bottle and puts it inside of a bigger bottle. **Obviously, he cannot put a bottle (say, of size 6) inside bigger bottle (say, of size 8) if the
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