随笔分类 -  图论

摘要:其实这题之前做过,线段树一直不熟,所以也一直没有搞懂 本题的关键是线段树原始区间代表的是每一种容器(size不同)的数量 比如 刚开始都是互不相关的,所以1的容器有n个 2 3 4。。。为0个 线段树每个结点的附加信息是该区间的和 本题查找出的代码是关键 比如左右子树分别为sum 27 25 ,则第 阅读全文
posted @ 2016-07-05 15:21 iEdson 阅读(298) 评论(0) 推荐(0)
摘要:IMMEDIATE DECODABILITY Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 12907 Accepted: 6188 Description An encoding of a set of symbols is 阅读全文
posted @ 2016-07-05 15:04 iEdson 阅读(236) 评论(0) 推荐(0)
摘要:最小生成树的定义:权值和最小的连通路 krus:每一步寻找原图最短路径(但是要安全边)加入 判断安全边可以用并查集 #include <iostream> #include <cstdio> #include <cstdlib> #include <cstring> #include <cmath> 阅读全文
posted @ 2016-06-15 01:23 iEdson 阅读(818) 评论(0) 推荐(0)
摘要:Catch the Theves Problem Description A group of thieves is approaching a museum in the country of zjsxzy,now they are in city A,and the museum is in c 阅读全文
posted @ 2016-06-10 18:36 iEdson 阅读(178) 评论(0) 推荐(0)
摘要:题意:动物逃跑,从左上跑到右下角,逃跑的路径是一个grid的边,现在动物园的工作人员要去拦截。input给出了grid每条路径拦截所需要的cost,题目要求拦截成功最小的成本。 经典的最小割问题,但是400*400个点太大了,所以不能直接这么做 lrj给出的方法是动物要从左上跑到右下,所有我们考虑怎 阅读全文
posted @ 2016-06-10 18:26 iEdson 阅读(215) 评论(0) 推荐(0)
摘要:#include <iostream> #include <cstdio> #include <cstdlib> #include <cstring> #include <cmath> #include <stack> #include <string> #include <queue> #incl 阅读全文
posted @ 2016-06-10 15:04 iEdson 阅读(161) 评论(0) 推荐(0)
摘要:Halum You are given a directed graph G(V, E) with a set of vertices and edges. Each edge (i, j) that connects some vertex i to vertex j has an integer 阅读全文
posted @ 2016-05-24 18:33 iEdson 阅读(150) 评论(0) 推荐(0)
摘要:Going in Cycle!! You are given a weighted directed graph with n vertices and m edges. Each cycle in the graph has a weight, which equals to sum of its 阅读全文
posted @ 2016-05-23 20:55 iEdson 阅读(155) 评论(0) 推荐(0)
摘要:The Toll! Revisited Sindbad the Sailor sold 66 silver spoons to the Sultan of Samarkand. The selling was quite easy; but delivering was complicated. T 阅读全文
posted @ 2016-05-12 16:48 iEdson 阅读(283) 评论(0) 推荐(0)
摘要:Warfare And Logistics The army of United Nations launched a new wave of air strikes on terroristforces. The objective of the mission is to reduce enem 阅读全文
posted @ 2016-05-11 20:16 iEdson 阅读(251) 评论(0) 推荐(0)
摘要:A Walk Through the Forest Problem Description Jimmy experiences a lot of stress at work these days, especially since his accident made working difficu 阅读全文
posted @ 2016-05-09 22:27 iEdson 阅读(262) 评论(0) 推荐(0)
摘要:Airport Express In a small city called Iokh, a train service, Airport-Express, takes residents to the airport more quickly than other transports. Ther 阅读全文
posted @ 2016-05-09 00:07 iEdson 阅读(202) 评论(0) 推荐(0)
摘要:MPI Maelstrom Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 7850 Accepted: 4818 Description BIT has recently taken delivery of their new 阅读全文
posted @ 2016-05-07 21:26 iEdson 阅读(170) 评论(0) 推荐(0)
摘要:Peaceful Commission Time Limit: 10000/5000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2853 Accepted Submission(s): 阅读全文
posted @ 2016-05-07 18:17 iEdson 阅读(175) 评论(0) 推荐(0)
摘要:Sorting It All Out Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 31940 Accepted: 11103 Description An ascending sorted sequence of distin 阅读全文
posted @ 2016-05-05 20:51 iEdson 阅读(289) 评论(0) 推荐(0)
摘要:Popular Cows Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 29141 Accepted: 11779 Description Every cow's dream is to become the most popu 阅读全文
posted @ 2016-05-03 19:22 iEdson 阅读(149) 评论(0) 推荐(0)
摘要:Knights of the Round Table Time Limit: 7000MS Memory Limit: 65536K Total Submissions: 11805 Accepted: 3870 Description Being a knight is a very attrac 阅读全文
posted @ 2016-05-03 00:57 iEdson 阅读(199) 评论(0) 推荐(0)
摘要:Network Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 11684 Accepted: 5422 Description A Telephone Line Company (TLC) is establishing a n 阅读全文
posted @ 2016-04-29 22:33 iEdson 阅读(341) 评论(0) 推荐(0)
摘要:Genealogical tree Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 4309 Accepted: 2866 Special Judge Description The system of Martians' blo 阅读全文
posted @ 2016-04-29 00:31 iEdson 阅读(169) 评论(0) 推荐(0)