18sui
18sui
全部文章
AcWing算...
AcWing other(1)
Acwing算法模板及理解(5)
AcWing算法竞赛进阶指南(3)
Mysql(1)
other(1)
洛谷(1)
归档
标签
去牛客网
登录
/
注册
wiseXu
请容我,再颓一次。20/10/12
全部文章
/ AcWing算法基础课
(共53篇)
AcWing 838. 堆排序
AcWing 838. 堆排序 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int h[N],num; void down(int u){ int t=u; if(u*2<...
AcWing
2020-07-30
0
278
AcWing 240. 食物链
AcWing 240. 食物链 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int n,m; int p[N],d[N]; //find函数返回的是根节点 int find(int x){ ...
AcWing
2020-07-30
0
278
AcWing 143. 最大异或对
AcWing 143. 最大异或对 /*暴力做法 int res=0; for(int i=0;i<n;i++) //枚举第一个数 for(int j=0;j<i;j++) //枚举第二个数 res=max(res,a[i]^a[j); */ #...
AcWing
算法竞赛进阶指南
2020-07-30
0
349
AcWing 839. 模拟堆
AcWing 839. 模拟堆 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; // h[N]存储堆中的值, h[1]是堆顶,x的左儿子是2x, 右儿子是2x + 1 // ph[k]存储第k个插入...
AcWing
2020-07-29
0
268
AcWing 837. 连通块中点的数量
AcWing 837. 连通块中点的数量 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int n,m; int p[N],num[N]; //返回x集合所在的集合+路径压缩 int find(i...
AcWing
2020-07-29
0
312
AcWing 836. 合并集合
AcWing 836. 合并集合 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int n,m; int p[N]; //返回x集合所在的集合+路径压缩 int find(int x){ ...
AcWing
2020-07-29
0
257
AcWing 835. Trie字符串统计
AcWing 835. Trie字符串统计 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int son[N][26],cnt[N],idx;//下标是0的点,既是根节点,又是空结点 char s...
AcWing
2020-07-29
0
322
AcWing 831. KMP字符串
AcWing 831. KMP字符串 #include <bits/stdc++.h> using namespace std; int n,m; const int N=1e5+10,M=1e6+10; //模板串 模式串 char p[N],s[M]; int ne[N]; i...
AcWing
2020-07-29
0
232
AcWing 154. 滑动窗口
AcWing 154. 滑动窗口 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int n,k; //q是队列 int a[N],q[N]; int main(){ scanf("...
AcWing
2020-07-29
0
358
AcWing 830. 单调栈
AcWing 830. 单调栈 #include <bits/stdc++.h> using namespace std; const int N=1e6+10; int n; int stk[N],tt; int main(){ cin.tie(0); ios::...
AcWing
2020-07-29
0
223
首页
上一页
1
2
3
4
5
6
下一页
末页