eight puzzle in java (bfs and A* algs implemented)