← All problemsSign in

Programmer Jackpot

Congratulations!!! You have been selected as a contestant on the show, Programmer's Jackpot tonight. For one of the rounds in the show, you face a problem as defined below : "For any positive integer 'X' , the sum of digits called as digit-sum of 'X', is defined as the sum of 'X' itself and its digits. When 'Y' is the digitsum of 'X' , we call 'X' a encore of 'Y'. For example, the digit-sum of 24

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