
解题报告
文章平均质量分 77
cyendra
Azarath Metrion Zinthos
展开
-
NEFU 644 touring compute 最短路
touring computeTime Limit 1000msMemory Limit 65536KdescriptionThe best friends Mr. Li and Mr. Liu are touring in beautiful country M. M ha原创 2013-04-06 18:20:57 · 758 阅读 · 0 评论 -
Codeforces 28B. pSort 连通性
B. pSorttime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputOne day n cells of some array decided to play the原创 2013-04-08 15:10:10 · 1756 阅读 · 0 评论 -
Codeforces 61D. Eternal Victory 树的性质
D. Eternal Victorytime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputValerian was captured by Shapur. The vic原创 2013-04-08 15:16:21 · 1609 阅读 · 0 评论 -
Codeforces 25D. Roads not only in Berland 并查集
D. Roads not only in Berlandtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputBerland Government decided to原创 2013-04-08 15:19:16 · 966 阅读 · 0 评论 -
Codeforces 117C. Cycle 寻找环
C. Cycletime limit per test2.5 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputA tournament is a directed graph without self-lo原创 2013-04-08 15:21:47 · 1479 阅读 · 0 评论 -
Codeforces 144D. Missile Silos 最短路
D. Missile Silostime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputA country called Berland consists of n cit原创 2013-04-08 15:31:29 · 1451 阅读 · 0 评论 -
Codeforces 34D. Road Map 树的遍历
D. Road Maptime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThere are n cities in Berland. Each city has it原创 2013-04-08 15:34:15 · 1421 阅读 · 0 评论 -
Codeforces 116C. Party 树的深度
C. Partytime limit per test3 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputA company has n employees numbered from 1 to n.原创 2013-04-08 16:27:45 · 1285 阅读 · 0 评论 -
Codeforces 103B. Cthulhu 寻找奈亚子
B. Cthulhutime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard output...Once upon a time a man came to the sea. The s原创 2013-04-08 15:49:39 · 1432 阅读 · 0 评论 -
Codeforces 24A. Ring road
A. Ring roadtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputNowadays the one-way traffic is introduced all原创 2013-04-08 15:59:40 · 1409 阅读 · 0 评论 -
Codeforces 131D. Subway 寻找环-树的最短路径
D. Subwaytime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputA subway scheme, classic for all Berland cities i原创 2013-04-08 16:22:03 · 1322 阅读 · 0 评论 -
Codeforces 107A. Dorm Water Supply 搜图
A. Dorm Water Supplytime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe German University in Cairo (GUC) d原创 2013-04-08 15:40:14 · 1470 阅读 · 0 评论 -
Codeforces 263 D. Cycle in Graph 环
D. Cycle in Graphtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou've got a undirected graph G, consisti原创 2013-04-08 15:46:53 · 1241 阅读 · 0 评论 -
Codeforces 217A. Ice Skating 搜索
A. Ice Skatingtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputBajtek is learning to skate on ice. He's a b原创 2013-04-08 16:08:19 · 1479 阅读 · 0 评论 -
Codeforces 246D. Colorful Graph
D. Colorful Graphtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputYou've got an undirected graph, consistin原创 2013-04-08 16:13:23 · 1056 阅读 · 0 评论 -
Codeforces 278C. Learning Languages 图的遍历
C. Learning Languagestime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe "BerCorp" company has got n emplo原创 2013-04-08 16:25:57 · 1269 阅读 · 0 评论 -
nefu 473 Drainage DitchesHal Burch 最大流
Drainage DitchesHal BurchTime Limit 1000msMemory Limit 65536KdescriptionEvery time it rains on Farmer John's fields, a pond forms over Bessie'原创 2013-04-08 20:27:38 · 892 阅读 · 0 评论 -
nefu 474 The Perfect StallHal Burch 二分图最大匹配
The Perfect StallHal BurchTime Limit 1000msMemory Limit 65536KdescriptionFarmer John completed his new barn just last week, complete with all原创 2013-04-09 09:52:54 · 996 阅读 · 0 评论 -
nefu 482 方格取数问题 二分图最大点权独立集
方格取数问题Time Limit 1000msMemory Limit 65536Kdescription 在一个有m*n 个方格的棋盘中,每个方格中有一个正整数。现要从方格中取数,使任意2 个数所在方格没有公共边,且取出的数的总和最大。试设计一个满足要求的取数算法。对于给定原创 2013-04-09 16:33:27 · 1320 阅读 · 0 评论 -
NEFU 485 分配问题
分配问题Time Limit 1000msMemory Limit 65536Kdescription 有n件工作要分配给n个人做。第i 个人做第j 件工作产生的效益为ij c 。试设计一个将n件工作分配给n个人做的分配方案,使产生的总效益最大。 对于给定的n件工作和n原创 2013-04-10 20:44:52 · 903 阅读 · 0 评论 -
欧拉回路的一点研究与Codeforces 62D Wormhouse
图G的一个回路,若它恰通过G中每条边一次,则称该回路为欧拉回路。具有欧拉回路的图称为欧拉图。欧拉回路就是从图上的一点出发,经过所有的边一次,最终回到起点的路径。首先是求出图中所有欧拉回路的朴素算法。深搜遍历所有的边,直到找到所有的欧拉回路。void dfs(int u,int deep){ ans[deep]=u;//将点u加入到路径中 if (deep==m)//若原创 2013-03-27 15:13:06 · 1094 阅读 · 1 评论 -
线性规划与网络流24题 1飞行员配对方案问题
飞行员配对方案问题Time Limit 1000msMemory Limit 65536Kdescription 第二次世界大战时期,英国皇家空军从沦陷国征募了大量外籍飞行员。由皇家空军派出的每一架飞机都需要配备在航行技能和语言上能互相配合的2 名飞行员,其中1 名是英国飞行员原创 2013-04-11 14:39:45 · 1151 阅读 · 0 评论 -
线性规划与网络流24题 2太空飞行计划问题 最大权闭合图问题(不懂) nefu 476
太空飞行计划问题Time Limit 1000msMemory Limit 65536Kdescription W教授正在为国家航天中心计划一系列的太空飞行。每次太空飞行可进行一系列商业性实验而获取利润。现已确定了一个可供选择的实验集合E={E1,E2,…,Em},和进行这些实原创 2013-04-09 15:38:24 · 1910 阅读 · 0 评论 -
线性规划与网络流24题 3最小路径覆盖问题 NEFU 481
最小路径覆盖问题Time Limit 1000msMemory Limit 65536Kdescription 给定有向图G=(V,E)。设P 是G 的一个简单路(顶点不相交)的集合。如果V 中每个顶点恰好在P 的一条路上,则称P是G 的一个路径覆盖。P 中路径可以从V 的任何原创 2013-04-10 19:17:18 · 1179 阅读 · 0 评论 -
线性规划与网络流24题 10餐巾计划问题
餐巾计划问题Time Limit 2000msMemory Limit 65536Kdescription 一个餐厅在相继的N 天里,每天需用的餐巾数不尽相同。假设第i天需要ri块餐巾(i=1,2,…,N)。餐厅可以购买新的餐巾,每块餐巾的费用为p分;或者把旧餐巾送到快洗部,洗原创 2013-04-12 18:40:42 · 1277 阅读 · 0 评论 -
UVa 111 - History Grading 最长递增子序列 LIS
History Grading BackgroundMany problems in Computer Science involve maximizing some measure according to constraints.Consider a history exam in which students are asked to put seve原创 2013-04-22 16:10:44 · 1132 阅读 · 0 评论 -
UVa 12018 - Juice Extractor 切水果dp----------暂时存疑
Juice Extractor Jerry loses himself in the interesting game: Fruit Ninja. Fruit Ninja is a game of iPhone and iPad in which the players cut the fruits coming from the bottom of the scree原创 2013-04-22 16:22:06 · 1259 阅读 · 0 评论 -
UVa 10405 - Longest Common Subsequence 最长公共子序列模板
Problem C: Longest Common SubsequenceSequence 1: Sequence 2: Given two sequences of characters, print the length of the longest common subsequence of both s原创 2013-04-22 16:49:16 · 938 阅读 · 0 评论 -
UVa 674 - Coin Change 背包dp
Coin Change Suppose there are 5 types of coins: 50-cent, 25-cent, 10-cent, 5-cent, and 1-cent. We want to make changes with these coins for a given amount of money.For example, if原创 2013-04-22 17:54:14 · 1193 阅读 · 0 评论 -
hdu 3853 LOOPS 圆环之理 概率dp
LOOPSTime Limit: 15000/5000 MS (Java/Others) Memory Limit: 125536/65536 K (Java/Others)Total Submission(s): 830 Accepted Submission(s): 342Problem DescriptionAkemi Homura is a Ma原创 2013-04-22 19:55:27 · 1078 阅读 · 0 评论 -
Codeforces 148D - Bag of mice 概率dp
D. Bag of micetime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputThe dragon and the princess are arguing abou原创 2013-04-22 20:41:03 · 1206 阅读 · 0 评论 -
poj 2151 Check the difficulty of problems 概率dp
Check the difficulty of problemsTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 3617 Accepted: 1580DescriptionOrganizing a programming contest is not原创 2013-04-22 21:32:46 · 1066 阅读 · 0 评论 -
网络流16数字梯形问题
数字梯形问题Time Limit 1000msMemory Limit 65536Kdescription 给定一个由n 行数字组成的数字梯形如下图所示。梯形的第一行有m 个数字。从梯形的顶部的m 个数字开始,在每个数字处可以沿左下或右下方向移动,形成一条从梯形的顶至底的路径。原创 2013-04-14 19:38:33 · 1067 阅读 · 0 评论 -
网络流 6最长递增子序列问题
最长递增子序列问题Time Limit 1000msMemory Limit 65536Kdescription给定正整数序列x1 , ... , xn 。(1)计算其最长递增子序列的长度s。(2)计算从给定的序列中最多可取出多少个长度为s的递增子序列。(3)如果允许在取出的序原创 2013-04-14 21:31:38 · 979 阅读 · 0 评论 -
10131 - Is Bigger Smarter? 水dp
Question 1: Is Bigger Smarter?The ProblemSome people think that the bigger an elephant is, the smarter it is. To disprove this, you want to take the data on a collection of elephants and put as原创 2013-04-23 20:53:41 · 955 阅读 · 0 评论 -
poj 3071 football 概率dp
FootballTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 2116 Accepted: 1055DescriptionConsider a single-elimination football tournament involving 2n原创 2013-04-23 09:53:39 · 1060 阅读 · 0 评论 -
线性规划与网络流24题 17运输问题
运输问题Time Limit 1000msMemory Limit 65536Kdescription W公司有m个仓库和n 个零售商店。第i 个仓库有ai 个单位的货物;第j 个零售商店需要bj个单位的货物。货物供需平衡,即。从第i 个仓库运送每单位货物到第j 个零售商店的费原创 2013-04-15 15:25:30 · 2562 阅读 · 0 评论 -
hdu 3415 Max Sum of Max-K-sub-sequence 单调队列dp
Max Sum of Max-K-sub-sequenceTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 4581 Accepted Submission(s): 1656Problem Description原创 2013-04-23 16:46:04 · 1060 阅读 · 0 评论 -
UVa 10192 - Vacation 字符串dp
Problem E: Vacation The ProblemYou are planning to take some rest and to go out on vacation, but you really don't know which cities you should visit. So, you ask your parents for hel原创 2013-04-23 21:38:25 · 944 阅读 · 0 评论 -
网络流24题 20深海机器人问题
深海机器人问题Time Limit 1000msMemory Limit 65536Kdescription 深海资源考察探险队的潜艇将到达深海的海底进行科学考察。潜艇内有多个深海机器人。潜艇到达深海海底后,深海机器人将离开潜艇向预定目标移动。深海机器人在移动中还必须沿途采集海原创 2013-04-15 19:38:53 · 872 阅读 · 0 评论