摘要: http://poj.org/problem?id=2049好纠结的一道题,刚拿过体来就已经懵了。这个图的信息到底该怎么存啊。。。纠结。看了别人的思路才A的。。he,ve两个数组分别存放这平行于x轴,y轴的墙,门信息。。。dis存储到达该点的最端距离。View Code #include <cstdio>#include <cstring>#include <queue>#define maxn 250#define inf 999999999using namespace std;struct node//优先队列的写法{ int x,y; int len 阅读全文
posted @ 2012-03-01 20:30 E_star 阅读(273) 评论(0) 推荐(0)
摘要: View Code #include <cstdio>#include <cstring>#include <iostream>#include <functional>#include <queue>using namespace std;int ar[13] = {14,10,56,7,83,22,36,91,3,47,72,0};struct cmp1{ bool operator ()(int &a,int &b) { return a > b;//以后面的b为准a》b所以小的先出来 }};struct 阅读全文
posted @ 2012-03-01 16:17 E_star 阅读(283) 评论(0) 推荐(0)