← All problemsSign in

Chef is Travelling

Chef is the king of a Country and conquered other country and wants to travel them.During that he plans to visit n cities.For city i ai is the maximum number of gift packs that an tourist is allowed to bring to the city, and bi is the number of citizens in the city. The Smart chef is going to bring some presents to the city he will be visiting. The presents are packed in gift packs, x presents in

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