- 博客(4)
- 收藏
- 关注
原创 HDU 4632 Palindrome subsequence(区间dp)
http://acm.hdu.edu.cn/showproblem.php?pid=4632 Problem Description In mathematics, a subsequence is a sequence that can be derived from another sequence by deleting some elements without changing
2018-01-27 14:10:37 111
原创 POJ 2955 Brackets 区间dp
http://poj.org/problem?id=2955 Description We give the following inductive definition of a “regular brackets” sequence: the empty sequence is a regular brackets sequence, if s is a regular bracket
2018-01-27 13:57:19 141
原创 双堆维护中位数
1,先把第一个数赋给mid 2,后来的数如果>=mid就插入到小顶堆 3,每次插入新的值后都保证小顶堆的大小与大顶堆相等或大1 4,最后的中位数就是mid(n为奇数),或者mid和小顶堆的堆顶元素的平均 priority_queueint,vectorint>,greaterint> >smallseq; priority_queueint,vectorint>,lessint> >bigs
2018-01-25 18:00:31 823
原创 hdu1817 Necklace of Beads(polya定理)
http://acm.hdu.edu.cn/showproblem.php?pid=1817 Problem Description Beads of red, blue or green colors are connected together into a circular necklace of n beads ( n Input The input has sever
2018-01-25 11:22:21 243
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人