随笔分类 -  数据结构

摘要:区间加、区间查询 #include<cstdio> #include<cstring> #include<iostream> #include<algorithm> using namespace std; const int N = 1e5 + 10; struct SegmentTree{ in 阅读全文
posted @ 2020-11-18 20:47 Lvlb2333 阅读(113) 评论(0) 推荐(0)
摘要:既然是队列那么先要包含头文件#include <queue> 队列(queue) 声明 queue<数据类型> 队列名称; queue<int> q; struct node{ int x; int y; } queue<node> q; 基本操作 push(x) 将x压入队列的末端 pop() 弹 阅读全文
posted @ 2020-10-06 19:59 Lvlb2333 阅读(273) 评论(1) 推荐(0)