Back to problems

Blind Maze Escape with a Fixed Command Sequence

Algorithm · Google · Hard

You are given a rectangular maze whose cells are marked with one of three symbols: # for a wall, . for an open cell you can stand on, and E for the single exit. Your starting cell is not known: it could be any of the . cells. While the plan runs you are effectively blind. You never learn where you are, and nothing tells you whether a given step actually moved you. A run finishes only once it arrives at E. Before starting, you must commit to one fixed list of commands. Every…

Loading the rest of the question…