摘要: 问题可以抽象为求起点到终点的最短路,其中经过x的代价是0,而经过.的代价是1,bfs的时候用优先队列即可。 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 7 const int N = 1001; ... 阅读全文
posted @ 2015-10-06 09:56 hxy_has_been_used 阅读(153) 评论(0) 推荐(0) 编辑