![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
贪心法
黑猫5027
摒弃时间之人所得不到的眷顾
展开
-
hdu 2037
今年暑假不ACTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 40706 Accepted Submission(s): 21773Problem Description“今年暑假不AC?”“是的。原创 2016-01-21 16:36:58 · 312 阅读 · 0 评论 -
POJ3617 字符串问题
Best Cow LineTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 15444 Accepted: 4363DescriptionFJ is about to take his N (1 ≤ N ≤ 2,000) cows to the annu原创 2016-01-25 21:09:00 · 1005 阅读 · 0 评论 -
POJ3069 贪心法 覆盖问题
Saruman's ArmyTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 6197 Accepted: 3165DescriptionSaruman the White must lead his army along a straight pa原创 2016-01-25 21:48:35 · 606 阅读 · 0 评论 -
POJ 3253 贪心法,优先队列
Fence RepairTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 35249 Accepted: 11392DescriptionFarmer John wants to repair a small length of the fence ar原创 2016-01-26 15:50:04 · 363 阅读 · 0 评论 -
ZOJ3607 2012浙江省省赛 贪心吧
表示这道题目今天模拟的时候做了将近三个小时都没有做出来,细节错误实在是太多了,心累啊。唉,最后还是看了一下别人的题解,打算明天好好在重新一份#include#include#includeusing namespace std;const int inf = 0x3f3f3f3f;const int maxn = 1000 + 50;int cnt, n原创 2016-03-05 20:50:49 · 500 阅读 · 0 评论 -
HDU 1257 vector。。。
都说用dp和贪心的。。。不过我也用的贪心的思想。。。反正就是每次取和现在vector中存放的高度里面相差最近的那个高度,然后修改就好了,如果vector中没有符合的,那就把他放入vector中再sort一下就好了最后答案就是v.len原创 2016-06-29 18:46:51 · 533 阅读 · 0 评论