Herman欧y
Herman欧y
全部文章
分类
题解(5)
归档
标签
去牛客网
登录
/
注册
Herman欧y的博客
全部文章
(共35篇)
题解 | #[NOIP2004]FBI树#
```#include <bits/stdc++.h> using namespace std; int n; string s; char fbi(int l,int r) { if(l==r) { if(s[l]=='0') { ...
C++
2026-01-02
0
6
题解 | #[NOIP2001]求先序排列#
#include <bits/stdc++.h> using namespace std; string s1, s2; // s1是中序,s2是后序 void solve(int l1, int r1, int l2, int r2) { if (l1 > r1) return...
C++
二叉树
2026-01-02
0
8
题解 | 汉诺塔
#include <bits/stdc++.h> using namespace std; void tower_hanio(int n,char start,char towards,char transport) { if(n==0)return ; tower_ha...
2026-01-02
0
8
题解 | #逆序对#
链接//【模板】逆序对的题解 #include <bits/stdc++.h>/*我们其实学久了就知道,我们排序的过程就是消灭逆序对的过程, 我们通过模拟归并排序,即可得出计算逆序对的方法*/ //旨在帮助大家养成动手模拟的好习惯 const int N = 5e5+10; usin...
C++
双指针
归并排序
数组
2026-01-01
0
14
题解 | 小红取数
#include<iostream> #include <vector> using namespace std; using ll =long long; int main(){ ll n; cin>>n; vector<ll&g...
2025-12-30
0
11
题解 | 多项式输出
#include <iostream> #include <vector> using namespace std; int main() { int n; cin >> n; vector<int>a(n + 1); ...
2025-12-30
0
8
题解 | 构造序列
#include <iostream> #include <cmath> using namespace std; int main(){ int n,m; cin>>n>>m; if(n==m){ cout&l...
2025-12-30
0
9
题解 | 【模板】队列操作
#include <iostream> #include <string> #include <queue> using namespace std; int main() { int n; cin >> n; queue&...
2025-12-29
0
12
题解 | 清楚姐姐买竹鼠
#include <iostream> #include <algorithm> #include <climits> using namespace std; using ll = long long; int main() { ll a, b, x;...
2025-12-28
0
15
题解 | 灵异背包?
#include <iostream> #include <vector> #include <algorithm> using namespace std; using ll = long long; int main() { ll n; ci...
2025-12-28
0
14
首页
上一页
1
2
3
4
下一页
末页