Solving 8-Puzzle with BFS (Breadth First Search) Algorithm
Find all the possible states of the 8-Puzzle starting from the given initial state until the goal node is reached. Note that, the states should be unique (no repetitions).
-
From the initial state of the puzzle, use different moves in all the directions to generate new states, check the validity of the newly generated node.
-
Implement back tracking to find the plan to solve the problem
cd <directory>
git clone https://github.com/nvnmangla/BFS.git
cd BFS
python3 solution.py
Libraries used
numpy ast