码迷,mamicode.com
首页 >  
搜索关键字:hdu 3001    ( 30933个结果
从一道简单的dp题中学到的...
今天想学点动态规划的知识,于是就看了杭电的课件,数塔问题啊,LCS啊都是比较经典的动规了,然后随便看了看就开始做课后练习题。。。HDOJ 1421 搬寝室http://acm.hdu.edu.cn/showproblem.php?pid=1421题目大意:从n(n 2 #include 3 #in....
分类:其他好文   时间:2014-07-19 15:11:48    阅读次数:299
UVa LA 4287 强连通 (类似 hdu 3836)
题目:https://icpcarchive.ecs.baylor.edu/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&category=25&problem=2288&mosmsg=Submission+received+...
分类:其他好文   时间:2014-07-19 15:09:20    阅读次数:313
小明系列问题——小明序列
hdu4521:http://acm.hdu.edu.cn/showproblem.php?pid=4521题解:给你一个序列,然后让你找一个最长上升子序列,但是这个最长上升子序列的数在原来序列的间隔不少于d。题解:如果没有d的要求就是一个求最长上升子序列。这里用线段树可以来优化。以数的值来建树。维...
分类:其他好文   时间:2014-07-19 09:34:12    阅读次数:283
HDU - 1087 Super Jumping! Jumping! Jumping!
还算是简单的DP问题,状态方程也不难。刚开始一看还以为是最长连续序列的最大值,想了老半天想不出状态方程。 1 #include 2 #include 3 #define doumax(a,b) (a>b?a:b) 4 const int maxn=1000+5; 5 int a[maxn],d[ma...
分类:其他好文   时间:2014-07-19 09:22:04    阅读次数:147
HDU 2896 AC自动机 + 细心
病毒侵袭Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 10478Accepted Submission(s): 2724Problem Descr...
分类:其他好文   时间:2014-07-19 09:17:54    阅读次数:410
hdu 1236 排名
结构体定义没搞明白,一直WA,终于AC了,真是高兴呀 代码如下: #include #include #include struct student { char id[30]; int score; }person[1001]; int cmp(const void *a,const void *b) { struct student *aa=(struct studen...
分类:其他好文   时间:2014-07-19 08:15:25    阅读次数:194
hdu 1251 字典树模板题 ---多串 查找单词出现次数
这道题题目里没有给定数据范围 我开了2005  疯狂的WA 然后开了50000, A掉  我以为自己模板理解错  然后一天没吃饭,饿得胃疼还是想着把这题A掉再去吃,谁知居然是这种问题,,,呵呵~~~ #include #include #include #include using namespace std; const int tk=26; const int t...
分类:其他好文   时间:2014-07-19 08:05:06    阅读次数:196
杭电 1051 Wooden Sticks
http://acm.hdu.edu.cn/showproblem.php?pid=1051 Wooden Sticks Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 11319    Accepted Submission(...
分类:其他好文   时间:2014-07-19 02:33:36    阅读次数:331
hdu 3294 Girls' research
#include #include #define MAX 200020 char s[MAX],ss[MAX*2],str[2]; int p[MAX*2]; int chance(char s) { return (s- str[0] + 26) % 26 + 'a'; } int min(int a,int b){return a>b?b:a;} int main() { ...
分类:其他好文   时间:2014-07-19 02:31:05    阅读次数:201
HDU 1594 find the max
数序问题。 题意是说 一个数列 a1,a2,……ai,……an;  x=i , y = ai;找两个点斜率绝对值!!最大。 第一次没找绝对值,……认真读题。。。 x 每次加1 。 只需要找 相邻的 ai 是否是最大就好了。 #include #include #include #include #include #include #include #include #...
分类:其他好文   时间:2014-07-19 02:25:35    阅读次数:168
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!