摘要: Burn the Linked CampTime Limit:2 Seconds Memory Limit:65536 KBIt is well known that, in the period of The Three Empires, Liu Bei, the emperor of the Shu Empire, was defeated by Lu Xun, a general of the Wu Empire. The defeat was due to Liu Bei's wrong decision that he divided his large troops int 阅读全文
posted @ 2013-08-30 11:35 码代码的猿猿 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 第一: 感觉难点在于建图 第二: ①:对于差分不等式,a - b = c ,建一条 b 到 a 的权值为 c 的边,求的是最长路,得到的是最小值 ③:存在负环的话是无解 ④:求不出最短路(dist[ ]没有得到更新)的话是任意解 第三: 一种建图方法: 设x是第i位置(或时刻)的值(跟所求值的属性一样),那么把x看成数列,前n项和为s[n],则x = s - s[i-1]; 那么这样就可以最起码... 阅读全文
posted @ 2013-08-30 08:18 码代码的猿猿 阅读(110) 评论(0) 推荐(0) 编辑
摘要: IntervalsTime Limit: 2000MSMemory Limit: 65536KTotal Submissions: 19359Accepted: 7308DescriptionYou are gi... 阅读全文
posted @ 2013-08-30 08:16 码代码的猿猿 阅读(127) 评论(0) 推荐(0) 编辑