8 puzzle problem using bfs in c