八数码——路径寻找问题

#include <cstdio> #include <cstring> #include <set> using namespace std; // 状态类型,每个状态都对应9个数 typedef int State[9]; const int maxState = 1000000; // 状态数组 State st[maxState], goal; // 距离数组 int dist[max
相关文章
相关标签/搜索