← All problemsSign in

Obsession

Ayush ($ayu111$) loves "1" too much and is obsessed with it.Now his friend, Shyamu introduced him a new digit "0". So he starts using it too. He creates numbers only with these two digits and creates a list with infinite numbers. Note that the list starts with 1, because he still loves "1" more. He asks you to guess the $N$th number in the list, if it is sorted in ascending order. ###Inpu

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