摘要: 这是一个在三维空间中找出口的最短路径问题,从出发点开始,广度优先遍历地图,记录到达各地所需的步数,然后,AC!但要小心,别漏了外加一层墙,不然就WA了(不加的话最外一层判断能否外的时候怎么办,哈哈)。#include #include #include using namespace std; const int maxn = 30 + 10; typedef struct Tnode //定义结点数据类型 { int x; int y; int z; }node; int L, R, C; char maze[maxn][maxn][max... 阅读全文
posted @ 2012-11-13 20:47 xiaodanding 阅读(201) 评论(0) 推荐(0) 编辑