Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Open Labyrinth by light2happy.718
def checkio(maze_map):
def walk(way, row, col):
if row == 10 and col == 10:
return way
if maze_map[row][col] != 0:
return None
maze_map[row][col] = 1
north = walk(way+'N', row-1, col)
south = walk(way+'S', row+1, col)
west = walk(way+'W', row, col-1)
east = walk(way+'E', row, col+1)
return north or south or west or east
return walk('', 1, 1)
May 24, 2015
Comments: