maze/bin/solve_maze.py

10 lines
173 B
Python
Raw Normal View History

import sys
from maze import parse_maze
2012-10-31 22:33:30 -07:00
if len(sys.argv) == 2:
m = parse_maze(open(sys.argv[1], 'r').read())
else:
m = parse_maze(sys.stdin.read())
print m.solve()