随笔分类 -  STL

HDU 4666 Hyperspace (2013多校7 1001题 最远曼哈顿距离)
摘要:HyperspaceTime Limit: 20000/10000 MS (Java/Others)Memory Limit: 65535/65535 K (Java/Others)Total Submission(s): 67Accepted Submission(s): 32Problem DescriptionThe great Mr.Smith has invented a hyperspace particle generator. The device is very powerful. The device can generate a hyperspace. In the hy 阅读全文

posted @ 2013-08-13 19:02 kuangbin 阅读(1198) 评论(0) 推荐(0)

HDU 4544 湫湫系列故事——消灭兔子 (优先队列)
摘要:湫湫系列故事——消灭兔子Time Limit: 3000/1000 MS (Java/Others)Memory Limit: 65535/32768 K (Java/Others)Total Submission(s): 138Accepted Submission(s): 49Problem Description 湫湫减肥 越减越肥! 最近,减肥失败的湫湫为发泄心中郁闷,在玩一个消灭免子的游戏。 游戏规则很简单,用箭杀死免子即可。 箭是一种消耗品,已知有M种不同类型的箭可以选择,并且每种箭都会对兔子造成伤害,对应的伤害值分别为Di(1 <= i <= M),每种箭需要一定的. 阅读全文

posted @ 2013-03-31 22:21 kuangbin 阅读(1328) 评论(1) 推荐(0)

STL Algorithms 之 unique
摘要:C++的文档中说,STL中的unique是类似于这样实现的:template <class ForwardIterator> ForwardIterator unique ( ForwardIterator first, ForwardIterator last ){ ForwardIterator result=first; while (++first != last) { if (!(*result == *first)) // or: if (!pred(*result,*first)) for the pred version *(++result)=*fi... 阅读全文

posted @ 2012-12-17 13:43 kuangbin 阅读(734) 评论(0) 推荐(0)

HDU 1075 What Are You Talking About (map,字符串替换)
摘要:What Are You Talking AboutTime Limit: 10000/5000 MS (Java/Others)Memory Limit: 102400/204800 K (Java/Others)Total Submission(s): 7959Accepted Submission(s): 2479Problem DescriptionIgnatius is so lucky that he met a Martian yesterday. But he didn't know the language the Martians use. The Martian 阅读全文

posted @ 2012-10-23 10:41 kuangbin 阅读(709) 评论(0) 推荐(0)

HDU 4268 Alice and Bob 第37届ACM/ICPC长春赛区网络赛1002题 (贪心+multiset)
摘要:Alice and BobTime Limit: 10000/5000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 627Accepted Submission(s): 245Problem DescriptionAlice and Bob's game never ends. Today, they introduce a new game. In this game, both of them have N different rectangular cards resp 阅读全文

posted @ 2012-09-10 19:45 kuangbin 阅读(803) 评论(0) 推荐(0)

HDU 4302 Holedox Eating(优先队列或者线段树)
摘要:Holedox EatingTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1830Accepted Submission(s): 634Problem DescriptionHoledox is a small animal which can be considered as one point. It lives in a straight pipe whose length is L. Holedox can only move alo 阅读全文

posted @ 2012-08-30 19:27 kuangbin 阅读(1111) 评论(0) 推荐(0)

HDU 4398 Template Library Management(贪心,STL)
摘要:Template Library ManagementTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 298Accepted Submission(s): 87Problem DescriptionAs an experienced ACMer, you must have known the importance of "code template library". With the help of pre-printe 阅读全文

posted @ 2012-08-27 18:40 kuangbin 阅读(782) 评论(0) 推荐(0)

HDU 4393 Throw nails (简单题)
摘要:Throw nailsTime Limit: 5000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 647Accepted Submission(s): 194Problem DescriptionThe annual school bicycle contest started. ZL is a student in this school. He is so boring because he can't ride a bike!! So he decided 阅读全文

posted @ 2012-08-27 14:01 kuangbin 阅读(613) 评论(0) 推荐(0)

HDU 4022 Bombing (STL应用)
摘要:BombingTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 65768/65768 K (Java/Others)Total Submission(s): 1377Accepted Submission(s): 533Problem DescriptionIt’s a cruel war which killed millions of people and ruined series of cities. In order to stop it, let’s bomb the opponent’s base.It seems not 阅读全文

posted @ 2012-08-23 16:07 kuangbin 阅读(1818) 评论(0) 推荐(0)

HDU 1027 Ignatius and the Princess II (产生第m大的排列,STLmap中的next_permutation(array,array+n);)
摘要:Ignatius and the Princess IITime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 2272Accepted Submission(s): 1371Problem DescriptionNow our hero finds the door to the BEelzebub feng5166. He opens the door and finds feng5166 is about to kill our pretty P 阅读全文

posted @ 2012-03-30 00:47 kuangbin 阅读(702) 评论(0) 推荐(0)

导航

JAVASCRIPT: