随笔分类 -  数据结构-平衡树-SBT

摘要:题目连接http://acm.hdu.edu.cn/showproblem.php?pid=5349MZL's simple problemDescriptionA simple problemProblem DescriptionYou have a multiple set,and now th... 阅读全文
posted @ 2015-09-09 23:03 GadyPu 阅读(229) 评论(0) 推荐(0)
摘要:题目连接http://acm.hdu.edu.cn/showproblem.php?pid=1541StarsDescriptionAstronomers often examine star maps where stars are represented by points on a plane... 阅读全文
posted @ 2015-06-24 21:26 GadyPu 阅读(132) 评论(0) 推荐(0)
摘要:题目连接http://acm.hdu.edu.cn/showproblem.php?pid=3282Running MedianDescriptionFor this problem, you will write a program that reads in a sequence of 32-b... 阅读全文
posted @ 2015-06-16 18:06 GadyPu 阅读(202) 评论(0) 推荐(0)
摘要:题目连接http://acm.hdu.edu.cn/showproblem.php?pid=1908Double QueueDescriptionThe new founded Balkan Investment Group Bank (BIG-Bank) opened a new office i... 阅读全文
posted @ 2015-06-11 16:56 GadyPu 阅读(184) 评论(0) 推荐(0)
摘要:题目连接http://acm.hdu.edu.cn/showproblem.php?pid=5249KPIDescription你工作以后, KPI 就是你的全部了. 我开发了一个服务,取得了很大的知名度。数十亿的请求被推到一个大管道后同时服务从管头拉取请求。让我们来定义每个请求都有一个重要值。我的... 阅读全文
posted @ 2015-05-31 19:19 GadyPu 阅读(357) 评论(0) 推荐(0)
摘要:原题链接:http://poj.org/problem?id=2418简单题。。平衡树,写了个模板。。动态分配内存确实很慢。。。 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 using std:... 阅读全文
posted @ 2015-05-05 20:02 GadyPu 阅读(212) 评论(0) 推荐(0)
摘要:原题链接:http://www.lydsy.com/JudgeOnline/problem.php?id=1862很恶心的 一道题,我也不晓得自己是第几次写这题了%>_ 2 #include 3 #include 4 #include 5 #include 6 #include 7 #i... 阅读全文
posted @ 2015-05-03 19:53 GadyPu 阅读(343) 评论(2) 推荐(0)
摘要:原题链接:http://acm.hdu.edu.cn/showproblem.php?pid=2648纯暴力的方法T_T。。。如下: 1 #include 2 #include 3 #include 4 #include 5 #include 6 typedef char State[3... 阅读全文
posted @ 2015-05-02 17:25 GadyPu 阅读(346) 评论(2) 推荐(0)
摘要:原题链接:http://acm.hust.edu.cn/vjudge/problem/viewProblem.action?id=46093 1 #include 2 #include 3 #include 4 #include 5 const int Max_N = 101000; 6... 阅读全文
posted @ 2015-05-01 17:16 GadyPu 阅读(212) 评论(0) 推荐(0)
摘要:原题链接:http://www.tyvj.cn/p/1728这道题以前用c语言写的treap水过了。。现在接触了c++用sbt重写一遍(速度比treap快一些)。。。sb树的一些基本操作都在里面了带垃圾回收,具体如下: 1 #include 2 #include 3 #include 4 #... 阅读全文
posted @ 2015-04-24 17:54 GadyPu 阅读(345) 评论(0) 推荐(0)