欢迎来到蒟蒻mqd的博客

随笔分类 -  主席树

摘要:P3834 【模板】可持久化线段树 1(主席树) 题目描述 如题,给定N个整数构成的序列,将对于指定的闭区间查询其区间内的第K小值。 输入格式: 第一行包含两个正整数N、M,分别表示序列的长度和查询的个数。 第二行包含N个整数,表示这个序列各项的数字。 接下来M行每行包含三个整数l,r,k l, r 阅读全文
posted @ 2019-05-11 15:11 mmqqdd 阅读(147) 评论(0) 推荐(0)
摘要:Distance on the tree 题目链接 https://nanti.jisuanke.com/t/38229 Describe DSM(Data Structure Master) once learned about tree when he was preparing for NOI 阅读全文
posted @ 2019-05-11 10:41 mmqqdd 阅读(261) 评论(0) 推荐(0)
摘要:Couple Trees Time Limit: 1 Sec Memory Limit: 256 MB 题目连接 http://hihocoder.com/problemset/problem/1232 Description "Couple Trees" are two trees, a husb 阅读全文
posted @ 2019-05-04 22:39 mmqqdd 阅读(315) 评论(0) 推荐(0)