#DFS does as far down a graph as it can go, whereas BFS goes as far across a graph that it can go visited = set() # a set makes it so that in visited, any repeats of ...
python pacman.py -l mediumMaze -p SearchAgent -a fn=bfs python pacman.py -l bigMaze -p SearchAgent -a fn=bfs -z .5 If Pacman moves too slowly for you, try the option --frameTime 0. python pacman.py -l ...