lll00077
lll00077
全部文章
分类
归档
标签
去牛客网
登录
/
注册
lll00077的博客
全部文章
(共15篇)
题解 | 二叉树遍历
/* 个人易忘:通过前序遍历序列复原二叉树。 */ #include <iostream> using namespace std; struct node { char val; node *left; node *right; node(ch...
2025-02-27
0
81
题解 | 日志排序
/* 抄的“汀州鹤眺”的代码,难难难 key: 1)struct思想,记录一整条记录,内部再拆分细节 2)学习myCmp的写法 3)getline的使用:读取包含空格的一整行,一般是换行符结束 亦可:cin.limits(numeric_limits<stream...
2025-02-26
0
42
题解 | 数字求和(vector排序:sort(nums.begin(), nums.end()))
#include <algorithm> #include <iostream> #include <vector> using namespace std; #define SIZE 5 int main() { int a; while (c...
2025-02-26
0
42
题解 | 字符串排序
#include <iostream> using namespace std; // 掌握字符串string的排序方法:sort(s.begin(),s.end()) int main() { string s; while (cin >> s) { /...
2025-02-26
0
50
题解 | 子串计算
#include <iostream> #include <map> using namespace std; struct dic { string key; int cnt = 0; }; int main() { string s;...
2025-02-26
0
49
首页
上一页
1
2
下一页
末页