impl 8-puzzle Solver