![](https://img-blog.csdnimg.cn/20201014180756922.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
dp
文章平均质量分 80
drrrrrrrrr
这个作者很懒,什么都没留下…
展开
-
The Heaviest Non-decreasing Subsequence Problem ACM-ICPC南宁wa
Let SS be a sequence of integers s_{1}s1, s_{2}s2, ......, s_{n}sn Each integer is is associated with a weight by the following rules: (1) If is is negative, then its weight is 00. (2)原创 2017-09-25 16:44:26 · 198 阅读 · 0 评论 -
POJ1260-Pearls(dp)
POJ1260 原题链接http://poj.org/problem?id=1260 Pearls Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 9562 Accepted: 4873 Description In Pearlania every原创 2017-09-10 16:16:19 · 212 阅读 · 0 评论 -
最长上升子序列(LIS)-O(nlogn)算法总结.
最近做了poj-1836这道题,用O(n^2)的LIS算法TLE了,百度了很久大概的学会了LIS的O(nlogn)算法; 最长上升子序列,简称LIS,O(n^2)的算法这里我就不写了,百度一下很容易理解; 1.首先定义一个数组num[n]:即为题目给出的序列; 2.其次定义一个数组LIS[len]:LIS[len]的值表示长度为len的子序列的最小末元素; 3. LIS[l原创 2017-09-12 18:16:59 · 5008 阅读 · 0 评论 -
poj1836-Alignment(LIS)
poj1836 原题链接:http://poj.org/problem?id=1836 Description 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 t原创 2017-09-12 19:17:56 · 282 阅读 · 0 评论 -
HDU1520-Anniversary party(树形dp)
Problem Description There is going to be a party to celebrate the 80-th Anniversary of the Ural State University. The University has a hierarchical structure of employees. It means that the supervi原创 2017-10-13 19:27:25 · 203 阅读 · 0 评论 -
Codeforces-462C. A Twisty Movement(前缀和/dp)
C. A Twisty Movementtime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard outputA dragon symbolizes wisdom, power and wealth. On Lunar New Year's Day, people m...原创 2018-03-19 18:32:45 · 247 阅读 · 0 评论