Rescue Balin
CodeChefOpen on judge ↗
Balin is stuck in a labyrinth beneath the lonely mountain and roof is about to collapse. Add a fire breathing dragon to the mix and it’s safe to say that he is desperate to get out of there as quickly as possible. Your task is to help him find the path to get out this pickle! The labyrinth is represented as a m-by-n matrix with Balin’s position marked as ‘s’ and the exit marked as ‘f’. Cells are
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