
STL 活用
文章平均质量分 80
hope1262946533
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
hdu 1029 Ignatius and the Princess IV【stl】
Ignatius and the Princess IV Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32767 K (Java/Others) Total Submission(s): 23179 Accepted Submission(s): 9696 Problem Description原创 2015-12-22 20:58:30 · 416 阅读 · 0 评论 -
CodeForces 246D. Colorful Graph【STL】
D. Colorful Graph time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output You've got an undirected graph, consistin原创 2016-05-22 09:25:40 · 486 阅读 · 0 评论 -
Poj 2907 Collecting Beepers【枚举+最短路径】
Collecting Beepers Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 2534 Accepted: 1369 Description Karel is a robot who lives in a rectangular coordina原创 2016-05-01 17:02:59 · 447 阅读 · 0 评论 -
Hdu 1716 排列2【stl+dfs排列组合】
排列2 Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others) Total Submission(s): 6391 Accepted Submission(s): 2467 Problem Description Ray又对数字的列产生了兴趣: 现有四张卡片,用这原创 2016-03-13 20:07:45 · 494 阅读 · 0 评论 -
函数库【收集中】
分享一下最近学习的函数 假设已经定义比较运算的数组x,则: 1, #include fill(x+a,x+b,c)无返回值 把x 数组内[a,b) 之间的数初始化为 C(亲测比循环赋值稍慢) 2, #include fill_n(x+a,b,c) 无返回值 把x 数组内[a,a+b) 之间的数初始化为 C (亲测比循环赋值稍快) 3, #include reverse(原创 2016-04-03 22:09:01 · 344 阅读 · 0 评论 -
20 吝啬的国度【邻接表+队列】
吝啬的国度 时间限制:1000 ms | 内存限制:65535 KB 难度:3 描述在一个吝啬的国度里有N个城市,这N个城市间只有N-1条路把这个N个城市连接起来。现在,Tom在第S号城市,他有张该国地图,他想知道如果自己要去参观第T号城市,必须经过的前一个城市是几号城市(假设你不走重复的路)。 输入第一行输入一个整数M表示测试数据共有M(1 每组测试数据原创 2015-08-28 15:36:49 · 428 阅读 · 0 评论 -
HDU 1058 Humble Numbers【巧用优先队列】
Humble Numbers Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others) Total Submission(s): 21717 Accepted Submission(s): 9480 Problem Description A number whose原创 2016-01-11 13:28:52 · 352 阅读 · 0 评论 -
UVa 12100 - Printer Queue【队列和优先队列】
原题网址: 题目说的是,有一些打印任务,每次只打印这些中最重要的,如果当前任务不是最重要的,就放在队尾,现在指定某一位置的一个任务,问什么时候把指定任务打印完成(打印每个需要 1 ) 题解: 用的优先队列判断是否是最大的那个值,其实不需要优先队列,只是顺手了而已,然后注意标记上自己的任务,无脑循环模拟。 #include #include #include using na原创 2016-01-08 14:32:18 · 544 阅读 · 0 评论 -
UVA 11991 - Easy Problem from Rujia Liu?【stl】
原文网址: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=3142 顺序给出n个数字和m次查询,查询时输入 k,v 输出从左到右第k个v 的下标,下标从1 到n。 训练指南的一道题,也是感觉不好处理,有点麻烦,然后发现代码这么简原创 2015-11-17 15:57:29 · 414 阅读 · 0 评论 -
UVA 11995 - I Can Guess the Data Structure!【stl】
原文网址: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&page=show_problem&problem=3146 挺恶心的一道题...需要判断多种状态,本来早写出来了,可是因为容器为空的时候,没特别注意,然后一re.... 其实自己也在猜测是不是这个原因..........原创 2015-11-17 20:49:09 · 484 阅读 · 0 评论 -
12C - Fruits
C. Fruits time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output The spring is coming and it means that a lot of fr原创 2016-07-21 10:30:13 · 866 阅读 · 0 评论