#include<iostream>
#include<cstdio>
#include<cstring>
#include<set>
using namespace std;
typedef int State[9];
const int maxstate = 1000000;
State st[maxstate], goal; //这个st数组就像一个队列 有front队首和rear队尾
int dist[maxstate];
const int dx[] = {-1, 1, 0, 0};
const int dy[] = {0, 0, -1, 1};
//===========================================================
//!!!!!使用的三种判重的方法!!!!
//===================================================
(隐式图)八数码问题(三种判重方法:排列计数、哈希技术、STL_set判重)
最新推荐文章于 2023-04-27 23:25:11 发布