![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
贪心
文章平均质量分 84
yuege38
在校学生,努力学习
展开
-
POJ3253_Fence Repair_贪心
Fence Repair Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 45697 Accepted: 14910 Description Farmer John wants to repair a small length of the fence ar原创 2017-03-17 16:16:06 · 289 阅读 · 0 评论 -
814D - An overnight dance in discotheque@tree dp||greedy
题意给出 n 个圆,每个圆给出圆心坐标和半径。任意两个圆之间最多只有一个公共点。将这 n 个圆放到两个坐标系内,使被奇数个圆覆盖的区域的面积最大,求这个最大面积。思路Tree DP任意两个圆最多只有一个公共点,也就是说两个圆的关系要么外离,要么内含。一个圆最多被一个圆直接包含。由此联想到树的结构,准确的说是森林,进而可以想到Tree DP的做法。Greedy后来看了官方神犇的题解,这个题完全可以贪心原创 2017-06-08 18:07:43 · 402 阅读 · 0 评论 -
HDU1789_Doing Homework again_贪心、并查集优
Doing Homework again Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 13285 Accepted Submission(s): 7741 Problem Description Igna原创 2017-02-19 17:34:34 · 273 阅读 · 0 评论 -
POJ1328_Radar Installation_贪心
Radar Installation Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 84620 Accepted: 18898 Description Assume the coasting is an infinite straight line. La原创 2017-04-04 00:55:29 · 279 阅读 · 0 评论 -
POJ3614_Sunscreen_贪心 && stl的优先级队列
Sunscreen Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 8256 Accepted: 2921 Description To avoid unsightly burns while tanning, each of the C (1 ≤ C ≤原创 2017-03-16 23:34:12 · 319 阅读 · 0 评论 -
POJ3617_Best Cow Line_贪心
Best Cow Line Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 22975 Accepted: 6261 Description FJ is about to take his N (1 ≤ N ≤ 2,000) cows to the annu原创 2017-03-17 14:17:26 · 280 阅读 · 0 评论 -
HDU2730_Painter_贪心
Painter Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 109 Accepted Submission(s): 62 Problem Description The local toy store s原创 2017-03-16 22:08:57 · 394 阅读 · 0 评论 -
HDU2037_今年暑假不AC_贪心
今年暑假不AC Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 55186 Accepted Submission(s): 29706 Problem Description “今年暑假不AC?” “是的。原创 2017-03-16 21:56:06 · 187 阅读 · 0 评论 -
HDU4310_Hero_贪心
Hero Time Limit: 6000/3000 MS (Java/Others) Memory Limit: 65536/65536 K (Java/Others) Total Submission(s): 4834 Accepted Submission(s): 2121 Problem Description When playing DotA wit原创 2017-02-21 20:59:33 · 299 阅读 · 0 评论 -
HDU4864_Task_贪心
Task Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 6721 Accepted Submission(s): 1786 Problem Description Today the company has原创 2017-02-21 21:28:27 · 339 阅读 · 0 评论 -
POJ3190_Stall Reservations_贪心
Stall Reservations Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 6315 Accepted: 2302 Special Judge Description Oh those picky N (1 <= N <= 50,000)原创 2017-02-22 22:40:28 · 787 阅读 · 0 评论 -
HDU5037_Frog_贪心
题意 池塘上有一根数轴,其中 0 点是岸边, m 点是对岸, 数轴上有一些石头。有一只青蛙从 0 点出发跳到 m 点,最大跳跃距离为 l。你可以在数轴上任意添加石头,使青蛙从 0 到 m 的过程中跳的次数最多。问,在青蛙总是采取最优策略的条件下,你最多能让它跳几次。 思路 首先想到 l + 1 的距离青蛙需要跳两次,尽量多地制造 l + 1 最符合我们的目标。 假设青蛙在石块 A[i]原创 2018-01-21 10:34:27 · 183 阅读 · 0 评论