Skip to content

nvnmangla/8-Puzzle-Solver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Description:

Solving 8-Puzzle with BFS (Breadth First Search) Algorithm


Steps Followed

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

Steps to Run

cd <directory>
git clone https://github.com/nvnmangla/BFS.git
cd BFS
python3 solution.py 

Libraries used

numpy ast