ACMIIITB2018P8
CodeChefOpen on judge ↗
Its the King of Asgard again. The king is planning to set a long relay racing. Asgard is a city of n junctions and m streets where all streets are unidirectional. In the relay, people have to follow the direction of the streets. People can walk the same street several times. For example, suppose Asgard contains 7 junctions and 7 streets. Junctions 1 and 3 are not connected to any other junctions
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