
STL
文章平均质量分 77
linyuxilu
我没有什么追求,只希望自己和关心我的家人和朋友都可以幸福!
展开
-
暑假集训第三周 STL G - 487-3279
G - 487-3279Time Limit:2000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionBusinesses like to have memorable telephone numbers. One way to ma原创 2015-07-27 21:13:42 · 392 阅读 · 0 评论 -
暑假集训第三周周六赛 STL D - 胜利大逃亡
D - 胜利大逃亡Time Limit:2000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 1253DescriptionIgnatius被魔王抓走了,有一天魔王出差去了,这可是Ignatius逃亡的好机会. 魔王住原创 2015-08-04 21:16:48 · 381 阅读 · 0 评论 -
暑假集训第四周周三赛F - Knight Moves 骑士的移动 STL
F - Knight MovesTime Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 1372DescriptionA friend of you is doing research on the Tra原创 2015-08-05 21:08:58 · 406 阅读 · 0 评论 -
暑假集训第三周STL L - Scavenger Hunt
L - Scavenger HuntTime Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit Status Practice POJ 2491DescriptionBackgroundBill has been the greatest boy原创 2015-09-26 14:45:23 · 369 阅读 · 0 评论 -
暑假集训第三周 STL 网页浏览器
123456789101112131415161718192021222324252627282930313233343536373839404142#include#includeint main(){ int i=0,max=0; char c[10],b[110][80]= {"ht原创 2015-09-26 10:34:08 · 393 阅读 · 0 评论 -
暑假集训第三周STL 大小写的全排列
C - AnagramTime Limit:1000MS Memory Limit:10000KB 64bit IO Format:%I64d & %I64uSubmit Status Practice POJ 1256DescriptionYou are to write a program that has to generate原创 2015-09-26 11:19:39 · 297 阅读 · 0 评论 -
STL源码学习----lower_bound和upper_bound算法
STL源码学习----lower_bound和upper_bound算法 STL中的每个算法都非常精妙,接下来的几天我想集中学习一下STL中的算法。 ForwardIter lower_bound(ForwardIter first, ForwardIter last,const _Tp& val)算法返回一个非递减序列[first, last)中的第一个大于等于值转载 2015-10-17 16:58:24 · 274 阅读 · 0 评论 -
606第七周周赛 C - Wavio Sequence最长递增递减序列
1 给定一串数字,求一个子串满足一下要求:子串的长度是L=2*n+1,前n+1个数字是严格的递增序列,后n+1个数字是严格的递减序列,例如123454321就是满足要求的一个子串,输出满足要求的最长的L,2、正着走一遍LIS,再倒着走一遍LIS,dp[i]表示前i个满足要求的数字的个数,那么dp1[i]和dp2[i]中最小的一个就是L的一半1234原创 2015-11-26 21:22:40 · 309 阅读 · 0 评论 -
AYITACM2016省赛第四周c- Fence Repair(优先队列,最大堆)
DescriptionFarmer John wants to repair a small length of the fence around the pasture. He measures the fence and finds that he needs N (1 ≤ N ≤ 20,000) planks of wood, each having some integer l原创 2016-05-10 09:01:51 · 704 阅读 · 0 评论 -
AYITACM2016省赛第四周D-Gunner(STL,map)
DescriptionLong long ago, there is a gunner whose name is Jack. He likes to go hunting very much. One day he go to the grove. There are $n$ birds and $n$ trees. The $i-th$ bird stands on the top o原创 2016-05-10 10:06:52 · 787 阅读 · 1 评论 -
nyoj 251 有趣的竞选(STL vector容器)
AMAZING AUCTION时间限制:3000 ms | 内存限制:65535 KB难度:4描述Recently the auction house has introduced a new type of auction, the lowest price auction. In this new system, people compete for the l原创 2016-05-05 14:34:19 · 272 阅读 · 0 评论 -
AYIT606第六周周六赛 (多重背包) E - Cash Machine 自动取款机
E - Cash MachineTime Limit:1000MS Memory Limit:10000KB 64bit IO Format:%I64d & %I64uSubmit Status Practice POJ 1276DescriptionA Bank plans to install a machine for cash原创 2016-04-20 17:38:16 · 549 阅读 · 0 评论 -
AYITACM2016省赛第一周(深搜+队列) A - 连连看
A - 连连看Time Limit:10000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit StatusDescription“连连看”相信很多人都玩过。没玩过也没关系,下面我给大家介绍一下游戏规则:在一个棋盘中,放了很多的棋子。如果某两个相同的棋子,可以通过一条线连起来(原创 2016-04-21 17:24:38 · 523 阅读 · 0 评论 -
nyoj 714 打牌的技巧(队列)
Card Trick 时间限制:1000 ms | 内存限制:65535 KB难度:3描述The magician shuffles a small pack of cards, holds it face down and performs the following proce原创 2016-05-19 21:24:45 · 287 阅读 · 0 评论 -
AYIT2016省赛集训第六周周一赛 H -高桥和低桥
高桥和低桥有个脑筋急转弯是这样的:有距离很近的一高一低两座桥,两次洪水之后高桥被淹了两次,低桥却只被淹了一次,为什么?答案是:因为低桥太低了,第一次洪水退去之后水位依然在低桥之上,所以不算“淹了两次”。举例说明:假定高桥和低桥的高度分别是5和2,初始水位为1第一次洪水:水位提高到6(两个桥都被淹),退到2(高桥不再被淹,但低桥仍然被淹)第二次洪水:水位提高到8(高桥又被淹了),原创 2016-05-23 21:41:00 · 500 阅读 · 0 评论 -
暑假集训第三周周三赛 STL C - Strange Class 字符相同 SC数
C - Strange ClassTime Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 5198DescriptionIn Vivid’s school, there is a strange class原创 2015-07-30 21:30:13 · 449 阅读 · 0 评论 -
暑假集训第三周周三赛 STL D - 产生冠军
D - 产生冠军Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 2094Description有一群人,打乒乓球比赛,两两捉对撕杀,每两个人之间最多打一场比赛。 球赛的规则如下: 如果A打败了B原创 2015-07-30 21:36:21 · 454 阅读 · 0 评论 -
暑假集训第三周周三赛 STL E - Gunner 射鸟
E - GunnerTime Limit:4000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 5199DescriptionLong long ago, there is a gunner whose name is Jac原创 2015-07-30 21:42:50 · 374 阅读 · 0 评论 -
暑假集训 第三周 STL I - Web Navigation网页导航
I - Web NavigationTime Limit:1000MS Memory Limit:10000KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionStandard web browsers contain features to move backward and原创 2015-07-28 21:28:34 · 290 阅读 · 0 评论 -
暑假集训第三周 STL N - Babelfish 翻译字典
N - BabelfishTime Limit:3000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionYou have just moved from Waterloo to a big city. The people here原创 2015-07-27 21:36:49 · 465 阅读 · 0 评论 -
暑假集训第三周 STL 双队列
E - Double QueueTime Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionThe new founded Balkan Investment Group Bank (BIG-Bank) opened原创 2015-07-28 21:16:35 · 393 阅读 · 0 评论 -
暑假集训第三周 STL S - Hat’s Words 合并单词
S - Hat’s WordsTime Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionA hat’s word is a word in the dictionary that is the concatenatio原创 2015-07-28 21:19:12 · 367 阅读 · 0 评论 -
暑假集训第三周 STL R - What Are You Talking About
R - What Are You Talking AboutTime Limit:5000MS Memory Limit:204800KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionIgnatius is so lucky that he met a Martian yester原创 2015-07-28 21:24:32 · 436 阅读 · 0 评论 -
南阳理工86 找球号
找球号(一)时间限制:3000 ms | 内存限制:65535 KB难度:3描述在某一国度里流行着一种游戏。游戏规则为:在一堆球中,每个球上都有一个整数编号i(0输入第一行有两个整数m,n(0接下来输入m+n个整数,前m个分别表示这m个球的编号i,后n个分别表示每次游戏中的随机整数k输出输出"YES"或"NO"样例输入6 423 3原创 2015-07-15 17:45:33 · 738 阅读 · 0 评论 -
暑假集训第三周 STL H - Election 选举
H - ElectionTime Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionCanada has a multi-party system of government. Each candidate is g原创 2015-07-27 21:21:30 · 564 阅读 · 0 评论 -
暑假集训第三周 STL D - 排列
D - 排列Time Limit:1000MS Memory Limit:30000KB 64bit IO Format:%I64d & %I64uSubmit StatusDescription题目描述: 大家知道,给出正整数n,则1到n这n个数可以构成n!种排列,把这些排列按照从小到大的顺序(字典顺序)列出,如n=3时,列出1 2原创 2015-07-28 19:54:09 · 267 阅读 · 0 评论 -
优先队列
概念优先级队列,顾名思义,就是一种根据一定优先级存储和取出数据的队列。它可以说是队列和排序的完美结合体,不仅可以存储数据,还可以将这些数据按照我们设定的规则进行排序。优先级队列是堆的一种常见应用。有最大优先级队列(最大堆)和最小优先级队列(最小堆)。优先级队列是一种维护有一组元素构成的集合S的数据结构。优先队列支持的基本运算[cpp] view plai转载 2015-07-29 11:35:35 · 359 阅读 · 0 评论 -
暑假集训第三周 STL T-看病要排队
T - 看病要排队Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit StatusDescription看病要排队这个是地球人都知道的常识。 不过经过细心的0068的观察,他发现了医院里排队还是有讲究的。0068所去的医院有三个医生(汗,这么原创 2015-07-29 13:25:34 · 432 阅读 · 0 评论 -
暑假集训第三周周三赛 STL F - 水果
F - 水果Time Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 1263Description夏天来了~~好开心啊,呵呵,好多好多水果~~ Joe经营着一个不大的水果店.他认为生存之道就是经营最受顾原创 2015-07-30 21:44:10 · 407 阅读 · 0 评论 -
暑假集训第三周周三赛 STL A - So easy 判断集合
A - So easyTime Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 5058DescriptionSmall W gets two files. There are n integers in e原创 2015-07-30 21:12:07 · 372 阅读 · 0 评论 -
暑假集训第三周周三赛 STL G - Intelligent IME
G - Intelligent IMETime Limit:1000MS Memory Limit:32768KB 64bit IO Format:%I64d & %I64uSubmit Status Practice HDU 4287Description We all use cell phone today. And we mus原创 2015-07-30 21:48:39 · 417 阅读 · 0 评论 -
暑假集训第三周 STL J - Catch That Cow 抓捕奶牛
J - Catch That CowTime Limit:2000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64uSubmit StatusDescriptionFarmer John has been informed of the location of a fugitive原创 2015-07-27 21:28:22 · 400 阅读 · 0 评论 -
51nod 1289 大鱼吃小鱼(stack)
有N条鱼每条鱼的位置及大小均不同,他们沿着X轴游动,有的向左,有的向右。游动的速度是一样的,两条鱼相遇大鱼会吃掉小鱼。从左到右给出每条鱼的大小和游动的方向(0表示向左,1表示向右)。问足够长的时间之后,能剩下多少条鱼?Input第1行:1个数N,表示鱼的数量(1 Output输出1个数,表示最终剩下的鱼的数量。Sample Input54 03 12 01 05 0原创 2017-04-17 22:02:26 · 368 阅读 · 0 评论