- 博客(11)
- 资源 (6)
- 收藏
- 关注
原创 poj 3411 Paid Roads -dfs
Paid RoadsA network of m roads connects N cities (numbered from 1 to N). There may be more than one road connecting one city with another. Some of the roads are paid. There are two ways to pay for travel on a paid road i from city ai to city bi:•in advan
2016-10-28 21:56:23 865
原创 hdu 5916 Harmonic Value Description-思维题-2016中国大学生程序设计竞赛(长春)-重现赛
Harmonic Value DescriptionThe harmonic value of the permutation p1,p2,⋯pn is∑i=1n−1gcd(pi.pi+1).Mr. Frog is wondering about the permutation whose harmonic value is the strictly k-th smallest among all the permutations of [n].
2016-10-28 21:26:07 377
原创 hdu 5912 Fraction -2016中国大学生程序设计竞赛(长春)
FractionMr. Frog recently studied how to add two fractions up, and he came up with an evil idea to trouble you by asking you to calculate the result of the formula below:As a talent, can you figure out the answer correctly?
2016-10-28 19:58:22 475
原创 poj 1836 Alignment -dp(合唱队形变式)-最长上升子序列+最长下降子序列
In the army, a platoon is composed by n soldiers. During the morning inspection, the soldiers are aligned in a straight line in front of the captain. The captain is not satisfied with the way his soldiers are aligned; it is true that the soldiers are align
2016-10-25 23:38:01 580
原创 poj 1054 The Troublesome Frog 枚举+二分搜索
In Korea, the naughtiness of the cheonggaeguri, a small frog, is legendary. This is a well-deserved reputation, because the frogs jump through your rice paddy at night, flattening rice plants. In the morning, after noting which plants have been flattened,
2016-10-25 16:35:44 446
原创 poj 1837 Balance -dp-01背包
BalanceGigel has a strange "balance" and he wants to poise it. Actually, the device is different from any other ordinary balance. It orders two arms of negligible weight and each arm's length is 15. Some hooks are attached to these arms and Gigel wants t
2016-10-22 16:44:03 312
原创 poj2135 Farm Tour -最小费用流
Farm TourDescriptionWhen FJ's friends visit him on the farm, he likes to show them around. His farm comprises N (1 <= N <= 1000) fields numbered 1..N, the first of which contains his house and the Nth of which contains the big barn. A total M (1 <= M <=
2016-10-19 21:14:44 501
原创 poj3469 Dual Core CPU-最小花费-最大流最小割
Dual Core CPUAs more and more computers are equipped with dual core CPU, SetagLilb, the Chief Technology Officer of TinySoft Corporation, decided to update their famous product - SWODNIW.The routine consists of N modules, and each of them should run in a
2016-10-18 23:28:12 266
原创 poj3281 Dining-网络流最大流-多对一的匹配
poj3281 DiningCows are such finicky eaters. Each cow has a preference for certain foods and drinks, and she will consume no others.Farmer John has cooked fabulous meals for his cows, but he forgot to check his menu against their preferences. Although he
2016-10-18 14:24:31 857 2
原创 poj 3041 Asteroids -二分匹配-最小顶点覆盖
AsteroidsBessie wants to navigate her spaceship through a dangerous asteroid field in the shape of an N x N grid (1 <= N <= 500). The grid contains K asteroids (1 <= K <= 10,000), which are conveniently located at the lattice points of the grid. Fortunat
2016-10-09 20:02:18 476
原创 网络流之最大流-Ford-Fullkerson算法 DFS && BFS
1、最大流的个人理解举例来说就是一个河流网,从a城市到b城市的河道中有的宽有的窄,问最大水流量能是多少,这个主要取决于这条路上的最窄的河道。2、Ford-Fullkerson算法 (挑战程序设计竞赛 P210)由于有很多条河道可选,例如 路径一:a—c—d—b 或者 路径二:a—c—f—b,按上面的想法,可能出现先走路径1和先走路径2产生的结果不一样,这时候可能是因为a-c这条
2016-10-06 19:24:14 1933
DOS 7.10 IOS镜像
2017-09-14
编译原理(清华大学出版社)课后题详解 第二版
2017-09-06
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人