Skip to content

🎲🐱 A ReactJS sliding puzzle with a solver and cat GIFs as your rewards.

Notifications You must be signed in to change notification settings

cedricblondeau/sliding-puzzle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sliding-puzzle

A ReactJS sliding puzzle with a solver and cat GIFs as your rewards.

forthebadge forthebadge

Live demo

https://cedricblondeau.github.io/sliding-puzzle/

Solver algorithm

The application uses A* search algorithm with Manhattan distance heuristic to solve puzzles. The algorithm solves 3x3 puzzles and some simple 4x4 puzzles but is unsuitable for more complex 4x4 ones.

See app/js/models/solver.js.

To solve 4x4 puzzles, Iterative_deepening_A* and a heuristic such as pattern database could be used.

Development

Install dependencies

npm install

Serve with Browsersync

gulp serve

CLI usage

node app/js/bin/console.js

Build

npm install
gulp build