← All problemsSign in

King of Codeland

Dom is the king of codeland. Brian, his best-friend wants to replace him. Brian wants to kill him in order to become king of codeland. Brian is standing on a rectangular grid of size n x m. The starting cell is marked 'S' and Dom is standing at cell marked with 'T', rest all the cells are marked with lowercase english alphabet (It is guaranteed that there is only one 'S' and one 'T' in the grid).

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