The Devil Number
CodeChefOpen on judge ↗
With the increasing popularity of Chef Po, many other chefs started to dislike him. So one day they decided that they will make chef Po indulge in a question so that he could not complete the food service in time, which will result in his unpopularity. They went to Chef Po and asked him, given a number N find the greatest Devil number K such that K Input First line of input contains a number T,
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