Mark And the Safe
CodeChefOpen on judge ↗
Mark is a rich person he keeps a lot of cash and jewellery in his safe. To open the safe one has to know the pattern of 1’s and 0’s present in the password. Rotate the safe wheel in clockwise direction if 1 is encountered else rotate anticlockwise. Mark is forgetful in nature so he keeps the clue of password written on a paper with him. Clue contains two numbers first number contains the pattern o
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