A Card And Time Game
CodeChefOpen on judge ↗
David and Monty are playing a game. David has a set of cards and each card is having a number written on it. The game starts at time t=1. One by one David will give cards to Monty and Monty will keep these cards in a box with timestamp at which he received the card. In one second David can give only one card so no two cards will have the same timestamp. But to make the game interesting David decid
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