腌萝卜干
腌萝卜干
全部文章
分类
未归档(199)
题解(7)
归档
标签
去牛客网
登录
/
注册
腌萝卜干的博客
全部文章
(共273篇)
题解 | #换个角度思考#
我最开始做的是线段树每个节点维护一个桶, 空间算错了, 直接爆了, 正确做法是主席树或者离线树状数组 将查询分为和, 分别查询累加贡献 #include <bits/stdc++.h> #define x first #define y second #define all(x) x....
2026-05-12
0
7
题解 | #小苯的前缀gcd构造#
以下是详细注释帮助理解版 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) vector&l...
2026-05-08
1
19
题解 | #操作数组#
简单题 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) vector<T> n...
2026-05-04
0
11
题解 | #【模板】整数域二分#
建议大家数组为的时候手写二分不容易出错 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) v...
2026-04-30
0
12
题解 | #旅行者的大逃脱#
因为时间, 因此可以考虑按照时间 定义状态表示表示时刻为并且到达位置的方案数 因为当前时刻只能从上一个时刻转移过来, 可以使用滚动数组优化, 注意是一个位置而是一个前缀, 行和列要分开处理 当第一次有方案数的时候说明就是最短时间, 对于每个一起累计答案就是最终的方案数 #include <bi...
2026-04-28
0
22
题解 | #Poi 的新加法(Easy Version)#
结论题 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) vector<T> n...
2026-04-26
0
15
题解 | #丛林木马#
观察表就能得到 假设所在的数字是, 所在的数字是, 贡献了的次数 那么将字符串倒过来, 然后计算每个位置上的值, 然后乘对方的大小, 就是当前位的贡献 #include <bits/stdc++.h> #define x first #define y second #define ...
2026-04-24
0
26
加了快读cin就不会 T 掉喵 | #异或和#
#include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) vector<T> name(...
2026-04-23
0
20
题解 | #弹珠游戏#
牛魔太难写了, 尤其是坐标映射 将原来的菱形转化为矩形然后分类讨论, 记忆化搜索 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define ve...
2026-04-22
0
18
题解 | #dd爱框框#
滑窗板子 #include <bits/stdc++.h> #define x first #define y second #define all(x) x.begin(), x.end() #define vec1(T, name, n, val) vector<T> ...
2026-04-21
0
26
首页
上一页
1
2
3
4
5
6
7
8
9
10
下一页
末页