
2-sat
文章平均质量分 73
elijahqi
这个作者很懒,什么都没留下…
展开
-
bzoj1997 [Hnoi2010]Planar
http://www.elijahqi.win/archives/3088 题目描述若能将无向图G=(V,E)画在平面上使得任意两条无重合顶点的边不相交,则称G是平面图。判定一个图是否为平面图的问题是图论中的一个重要问题。现在假设你要判定的是一类特殊的图,图中存在一个包含所有顶点的环,即存在哈密顿回路。输入输出格式输入格式:输入文件的第一行是一个正整数T,表示数据组数(每组数据...原创 2018-04-14 15:14:04 · 179 阅读 · 0 评论 -
bzoj 4945 &UOJ 317 [Noi2017]游戏
http://www.elijahqi.win/archives/3471 题目背景 狂野飙车是小 L 最喜欢的游戏。与其他业余玩家不同的是,小 L 在玩游戏之余,还精于研究游戏的设计,因此他有着与众不同的游戏策略。题目描述 小 L 计划进行 nn 场游戏,每场游戏使用一张地图,小 L 会选择一辆车在该地图上完成游戏。小 L 的赛车有三辆,分别用大写字母A、B、C表示。地图...原创 2018-05-24 23:26:13 · 260 阅读 · 0 评论 -
codeforces 875c National Property
http://www.elijahqi.win/archives/1305 You all know that the Library of Bookland is the largest library in the world. There are dozens of thousands of books in the library.Some long and uninteresti...原创 2018-05-14 23:52:10 · 260 阅读 · 0 评论 -
poj2749 Building roads
http://www.elijahqi.win/archives/3083 DescriptionFarmer John’s farm has N barns, and there are some cows that live in each barn. The cows like to drop around, so John wants to build some roads to c...原创 2018-04-13 23:51:38 · 125 阅读 · 0 评论 -
poj2723 Get Luffy Out
http://www.elijahqi.win/archives/3079 Description Ratish is a young man who always dreams of being a hero. One day his friend Luffy was caught by Pirate Arlong. Ratish set off at once to Arlong’s is...原创 2018-04-13 23:47:06 · 174 阅读 · 0 评论 -
poj3648 Wedding
http://www.elijahqi.win/archives/3077 DescriptionUp to thirty couples will attend a wedding feast, at which they will be seated on either side of a long table. The bride and groom sit at one end, ...原创 2018-04-13 23:42:47 · 123 阅读 · 0 评论 -
poj3678 Katu Puzzle
http://www.elijahqi.win/archives/3073 DescriptionKatu Puzzle is presented as a directed graph G(V, E) with each edge e(a, b) labeled by a boolean operator op (one of AND, OR, XOR) and an integer c...原创 2018-04-13 16:05:43 · 200 阅读 · 0 评论 -
poj3683 Priest John's Busiest Day
http://www.elijahqi.win/archives/3069 DescriptionJohn is the only priest in his town. September 1st is the John’s busiest day in a year because there is an old legend in the town that the couple w...原创 2018-04-13 14:28:14 · 139 阅读 · 0 评论 -
poj3207 Ikki's Story IV - Panda's Trick
http://www.elijahqi.win/archives/3066 Descriptionliympanda, one of Ikki’s friend, likes playing games with Ikki. Today after minesweeping with Ikki and winning so many times, he is tired of such ea...原创 2018-04-13 09:44:03 · 155 阅读 · 0 评论 -
bzoj2199 [Usaco2011 Jan]奶牛议会
http://www.elijahqi.win/archives/3003 Description 由于对Farmer John的领导感到极其不悦,奶牛们退出了农场,组建了奶牛议会。议会以“每头牛 都可以获得自己想要的”为原则,建立了下面的投票系统: M只到场的奶牛 (1 <= M <= 4000) 会给N个议案投票(1 <= N <= 1,000) 。每只 奶牛会对...原创 2018-04-10 00:20:41 · 187 阅读 · 0 评论 -
bzoj1823 [JSOI2010]满汉全席
http://www.elijahqi.win/archives/3094 Description满汉全席是中国最丰盛的宴客菜肴,有许多种不同的材料透过满族或是汉族的料理方式,呈现在數量繁多的菜色之中。由于菜色众多而繁杂,只有极少數博学多闻技艺高超的厨师能够做出满汉全席,而能够烹饪出经过专家认证的满汉全席,也是中国厨师最大的荣誉之一。 世界满汉全席协会是由能够料理满汉全席的专家厨师们所组成,...原创 2018-04-15 08:26:21 · 171 阅读 · 0 评论 -
bzoj 3495 PA2010 Riddle
http://www.elijahqi.win/archives/3465 Description 有n个城镇被分成了k个郡,有m条连接城镇的无向边。 要求给每个郡选择一个城镇作为首都,满足每条边至少有一个端点是首都。Input 第一行有三个整数,城镇数n(1<=n<=10^6),边数m(0<=m<=10^6),郡数k(1<=k<=n)。 接下来...原创 2018-05-24 19:24:52 · 239 阅读 · 0 评论