上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 22 下一页
摘要: 题文:https://vjudge.net/problem/UVA-12167 题解: 很明显,先要缩点。然后画一下图就会发现是入度为0的点和出度为0的点取max。 代码: 阅读全文
posted @ 2017-09-13 08:21 人间失格—太宰治 阅读(239) 评论(0) 推荐(0)
摘要: 题文:https://vjudge.net/problem/UVA-11324 题解: 这个题目首先可以发现,只要是一个强连通分量,要么都选,要么都不选,将点权看成强连通分量的点数,所以这个题目就转化成了DAG上的最大路。 稍微dp一下就好了。 代码: 阅读全文
posted @ 2017-09-12 22:22 人间失格—太宰治 阅读(243) 评论(0) 推荐(0)
摘要: Farmer John goes to Dollar Days at The Cow Store and discovers an unlimited number of tools on sale. During his first visit, the tools are selling var 阅读全文
posted @ 2017-09-12 16:22 人间失格—太宰治 阅读(136) 评论(0) 推荐(0)
摘要: Keeping track of all the cows can be a tricky task so Farmer John has installed a system to automate it. He has installed on each cow an electronic ID 阅读全文
posted @ 2017-09-12 15:59 人间失格—太宰治 阅读(240) 评论(0) 推荐(0)
摘要: Farmer John's N (1 <= N <= 50,000) cows (numbered 1..N) are planning to run away and join the circus. Their hoofed feet prevent them from tightrope wa 阅读全文
posted @ 2017-09-12 12:05 人间失格—太宰治 阅读(421) 评论(0) 推荐(2)
摘要: In Korea, the naughtiness of the cheonggaeguri, a small frog, is legendary. This is a well-deserved reputation, because the frogs jump through your ri 阅读全文
posted @ 2017-09-12 11:17 人间失格—太宰治 阅读(380) 评论(0) 推荐(0)
摘要: A 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 阅读全文
posted @ 2017-09-11 21:55 人间失格—太宰治 阅读(182) 评论(0) 推荐(0)
摘要: 给出硬币面额及每种硬币的个数,求从1到m能凑出面额的个数。 Input 多组数据,每组数据前两个数字为n,m。n表示硬币种类数,m为最大面额,之后前n个数为每种硬币的面额,后n个数为相应每种硬币的个数。 (n<=100,m<=100000,面额<=100000,每种个数<=1000) Output 阅读全文
posted @ 2017-09-11 20:34 人间失格—太宰治 阅读(200) 评论(0) 推荐(0)
摘要: "Fat and docile, big and dumb, they look so stupid, they aren't much fun..." - Cows with Guns by Dana Lyons The cows want to prove to the public that 阅读全文
posted @ 2017-09-11 19:35 人间失格—太宰治 阅读(227) 评论(0) 推荐(0)
摘要: 【题目背景】 小奇总是在数学课上思考奇怪的问题。 【问题描述】 给定一个n*m的矩阵,矩阵中的每个元素aij为正整数。 接下来规定 1.合法的路径初始从矩阵左上角出发,每次只能向右或向下走,终点为右下角。 2.路径经过的n+m-1个格子中的元素为A1,A2…A(n+m-1),Aavg为Ai的平均数, 阅读全文
posted @ 2017-09-11 17:32 人间失格—太宰治 阅读(691) 评论(0) 推荐(3)
上一页 1 ··· 6 7 8 9 10 11 12 13 14 ··· 22 下一页