随笔分类 -  数据结构- Treap / Splay

摘要:好久没打过数据结构了哈... 把这道题作为splay 的复习题吧,也是个板子. 题目描述 Tiger最近被公司升任为营业部经理,他上任后接受公司交给的第一项任务便是统计并分析公司成立以来的营业情况。 Tiger拿出了公司的账本,账本上记录了公司成立以来每天的营业额。分析营业情况是一项相当复杂的工作。 阅读全文
posted @ 2018-05-31 19:30 Kevin_naticl 阅读(251) 评论(0) 推荐(0)
摘要:#include using namespace std; #define maxn 200000 int read() { char ch=getchar();int f=1,w=0; while(ch'9'){if(ch=='-')f=-1;ch=getchar();} while(ch='0'){w=w*10+ch-'0';ch=getchar();} re... 阅读全文
posted @ 2018-01-13 15:36 Kevin_naticl 阅读(303) 评论(0) 推荐(1)