摘要: poj2983——差分约束,bellman_fordIs the Information Reliable?Time Limit:3000MSMemory Limit:131072KTotal Submissions:11560Accepted:3658DescriptionThe galaxy w... 阅读全文
posted @ 2015-04-09 23:56 __560 阅读(241) 评论(0) 推荐(0) 编辑
摘要: poj1201——差分约束,spfaIntervalsTime Limit:2000MSMemory Limit:65536KTotal Submissions:22553Accepted:8530DescriptionYou are given n closed, integer interval... 阅读全文
posted @ 2015-04-09 21:55 __560 阅读(379) 评论(0) 推荐(0) 编辑
摘要: 图的邻接表存储struct Edge{ int v; ll w; Edge *next;};Edge e[maxn*10];void add_edge(int u,int v,ll w) ///插入邻接表的首部而非尾部,避免遍历{ Edge *pre=&e[u]; Ed... 阅读全文
posted @ 2015-04-09 17:42 __560 阅读(165) 评论(0) 推荐(0) 编辑
摘要: hiho1093 ——spfa时间限制:10000ms单点时限:1000ms内存限制:256MB描述万圣节的晚上,小Hi和小Ho在吃过晚饭之后,来到了一个巨大的鬼屋!鬼屋中一共有N个地点,分别编号为1..N,这N个地点之间互相有一些道路连通,两个地点之间可能有多条道路连通,但是并不存在一条两端都是同... 阅读全文
posted @ 2015-04-09 17:37 __560 阅读(251) 评论(0) 推荐(0) 编辑
摘要: poj1716——差分约束Integer IntervalsTime Limit:1000MSMemory Limit:10000KTotal Submissions:13029Accepted:5516DescriptionAn integer interval [a,b], a =2,0=2,s... 阅读全文
posted @ 2015-04-09 14:58 __560 阅读(234) 评论(0) 推荐(0) 编辑