Roommates
CodeChefOpen on judge ↗
Bob and Alice are two good friends. Alice tells every secret to Bob. On one fine day Bob was blackmailing Alice as he will tell that secret to everyone. Alice is quiet good so she asks Bob if he can answer her question correctly he can tell that secret to everyone. The problem goes as follows,"Can you find the next greater number whose taste is same as the number he gave.” where Alice's taste of n
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