King of Chefland
CodeChefOpen on judge ↗
The King of Chefland, as you can all guess, is Chef himself. Chef loves his territory so much that he has built Palace for himself in every city of his territory. Every weekend, Chef loves to travel from one city S to another city D within his territory and spend the week in his palace in city D. But, every road in Chefland connecting one city to another is unidirectional road, i.e. one can move o
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