![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
贪心
文章平均质量分 71
csdn_PatrickStar
这个作者很懒,什么都没留下…
展开
-
Allowance(贪心+STL)
Problem:AllowanceDescription:As a reward for record milk production, Farmer John has decided to start paying Bessie the cow a small weekly allowance. FJ has a set of coins in N (1 <= N <= 20) ...原创 2018-12-04 14:28:52 · 419 阅读 · 0 评论 -
悼念512汶川大地震遇难同胞——老人是真饿了(贪心+STL)
Problem:悼念512汶川大地震遇难同胞——老人是真饿了Description:对于幸存的灾民来说,最急待解决的显然是温饱问题,救灾部队一边在组织人员全力打通交通,一边在组织采购粮食。现在假设下拨了一定数量的救灾经费要去市场采购大米(散装)。如果市场有m种大米,各种大米的单价和重量已知,请问,为了满足更多灾民的需求,最多能采购多少重量的大米呢?Input:输入数据首先包含一个正整数C,...原创 2018-12-05 17:21:46 · 163 阅读 · 0 评论 -
今年暑假不AC(贪心+STL)
Problem:今年暑假不ACDescription:“今年暑假不AC?”“是的。”“那你干什么呢?”“看世界杯呀,笨蛋!”“@#$%^&*%…”确实如此,世界杯来了,球迷的节日也来了,估计很多ACMer也会抛开电脑,奔向电视了。作为球迷,一定想看尽量多的完整的比赛,当然,作为新时代的好青年,你一定还会看一些其它的节目,比如新闻联播(永远不要忘记关心国家大事)、非常6+7、...原创 2018-12-03 16:02:38 · 113 阅读 · 0 评论 -
Repair the Wall(贪心+STL)
Problem:Repair the WallDescription:Long time ago , Kitty lived in a small village. The air was fresh and the scenery was very beautiful. The only thing that troubled her is the typhoon.When the typ...原创 2018-12-05 12:33:23 · 124 阅读 · 0 评论 -
Saving HDU(贪心+STL)
Problem:Saving HDUDescription:话说上回讲到海东集团面临内外交困,公司的元老也只剩下XHD夫妇二人了。显然,作为多年拼搏的商人,XHD不会坐以待毙的。一天,当他正在苦思冥想解困良策的时候,突然想到了自己的传家宝,那是公司成立的时候,父亲作为贺礼送来的一个锦囊,徐父当时交代,不到万不得已的时候,不要打开它。“现在不正是最需要的时候吗?”,一边想,XHD一边找到了这个...原创 2018-12-05 11:32:04 · 206 阅读 · 1 评论 -
Tian Ji -- The Horse Racing(贪心+STL)
Problem:Tian Ji – The Horse RacingDescription:Here is a famous story in Chinese history.“That was about 2300 years ago. General Tian Ji was a high official in the country Qi. He likes to play horse...原创 2018-12-05 11:12:57 · 223 阅读 · 0 评论 -
Fence Repair(贪心+STL)
Problem:Fence RepairDescription:Farmer John wants to repair a small length of the fence around the pasture. He measures the fence and finds that he needs N (1 ≤ N ≤ 20,000) planks of wood, each havi...原创 2018-12-03 00:03:41 · 126 阅读 · 0 评论 -
Saruman's Army(贪心)
Problem:Saruman’s ArmyDescription:Saruman the White must lead his army along a straight path from Isengard to Helm’s Deep. To keep track of his forces, Saruman distributes seeing stones, known as pa...原创 2018-12-03 00:01:55 · 114 阅读 · 0 评论 -
Best Cow Line(贪心)
Problem:Best Cow LineDescription:FJ is about to take his N (1 ≤ N ≤ 2,000) cows to the annual"Farmer of the Year" competition. In this contest every farmer arranges his cows in a line and herds them...原创 2018-12-02 22:13:10 · 293 阅读 · 0 评论 -
Wooden Sticks(贪心+STL)
Problem:Wooden SticksDescription:There is a pile of n wooden sticks. The length and weight of each stick are known in advance. The sticks are to be processed by a woodworking machine in one by one f...原创 2018-12-04 21:45:07 · 136 阅读 · 0 评论 -
Moving Tables(贪心+STL)
Problem:Moving TablesDescription:The famous ACM (Advanced Computer Maker) Company has rented a floor of a building whose shape is in the following figure.The floor has 200 rooms each on the north ...原创 2018-12-04 16:55:55 · 142 阅读 · 0 评论 -
School Marks(贪心)
Problem:School MarksDescription:Little Vova studies programming in an elite school. Vova and his classmates are supposed to write n progress tests, for each test they will get a mark from 1 to p. Vo...原创 2018-12-03 18:18:15 · 270 阅读 · 0 评论