← All problemsSign in

Loot of the Rooks

Jacob and evie are the leaders of a gang named ROOKS consisting of n members. Some of the gang members work together in the form of groups. Each gang member has x money weighing y units. Each group has to report to jacob with max money of its members . Each group has been alloted a bag weighing a units. Moreover the contribution of the leader in a groups contribution is must(if possible).The lea

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