We will develop code to generate simple mazes in Python and find paths in them to navigate from a starting node to a goal node. Along the way, we will learn the fundamental search algorithms depth-first search, breadth-first search, and A*. To support these algorithms, we will also learn the stack, queue, and priority queue data structures.
The examples are from chapter 2 of Classic Computer Science Problems in Python.
[ Ссылка ]
All of the code is available in the chapter 2 folder of the Classic Computer Science Problems in Python GitHub repository.
[ Ссылка ]
The Maze Solving GUI is also available on GitHub.
[ Ссылка ]
I made a small mistake in the explanation of A*, I meant to say the explored dictionary is storing the g(n) so far, not the f(n). Sorry!
Follow me on Twitter
[ Ссылка ]
Find out more about the Classic Computer Science Problems series, including the books in Java and Swift
[ Ссылка ]
Ещё видео!