Ginie and his Mischief
CodeChefOpen on judge ↗
The Ginie is tired of following out Aladdin's whimsical commands. Now Aladding has a lot of lamps, each numbered with a positive integer and he does not remeber the number of the lamp in which the Ginie resides. All he remembers is that the Ginnie resides in the first lamp. The Ginie wishes to reverse the order in which the lamps are arranged so that Aladdin has to try every lamp before he reaches
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