千早爱音a
千早爱音a
全部文章
分类
归档
标签
去牛客网
登录
/
注册
千早爱音a的博客
全部文章
(共79篇)
题解 | 序列链表化
/** * struct ListNode { * int val; * struct ListNode *next; * ListNode(int x) : val(x), next(nullptr) {} * }; */ class Solution { public: /*...
2025-12-17
1
7
题解 | 小苯的比赛上分
#include <iostream> #include <queue> #include <vector> #include <set> using namespace std; //本题的要求我们每次对一组数据种的最小值进行操作,操作m次以后输出数...
2025-12-01
0
13
题解 | 两端问优先队列
#include <iostream> #include <queue> #include <set> #include <vector> using namespace std; //本题是类模板题,实质上就是操作一个多重集合 int main() ...
2025-12-01
0
13
题解 | 字符串优先队列
#include<bits/stdc++.h> using namespace std; //本题真的需要题解吗(存疑),已经都写好了 priority_queue<string, vector<string>, greater<string> > s...
2025-11-30
0
9
题解 | 结构体优先队列
#include<bits/stdc++.h> using namespace std; //本题类似的题目其实在结构体那块写过,只是这里多了单科判断 //只需要重载运算符就好了 struct node{ int chinese, math, english, sum; }; ...
2025-11-30
0
8
题解 | 【模板】整数优先队列
#include <iostream> #include <queue> //优先队列的头文件也是queue using namespace std; //本题为模板题,没有特别的说明,学习语法即可 int main() { priority_queue<int...
2025-11-30
0
8
题解 | 不重复数字
#include <iostream> #include <vector> #include <set> //本题使用到序列和集合内容 using namespace std; int main() { //本题需要每次查找第ai项之前的每一项是否含有与其相...
2025-11-29
0
9
题解 | 宝石计数
class Solution { public: /** * 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 * * * @param jewels string字符串 * @param stones strin...
2025-11-27
0
8
题解 | 快乐数
class Solution { public: /** * 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 * * * @param n int整型 * @return bool布尔型 */ ...
2025-11-27
0
11
题解 | 数对计数
#include<bits/stdc++.h> using namespace std; int main(){ //本题解来自牛客er@Nitrene,我仅探讨自己的理解,如有侵权请联系删除 multiset<int> A;//因为要包括出现次数,所以要开多重集...
2025-11-27
0
18
首页
上一页
1
2
3
4
5
6
7
8
下一页
末页