佛系的青年
佛系的青年
全部文章
分类
归档
标签
去牛客网
登录
/
注册
佛系的青年的博客
全部文章
(共89篇)
题解 | 字符串通配符
#include <iostream> #include <vector> #include <cctype> using namespace std; bool isMatch(const string& s, const string& p)...
2025-03-06
0
39
题解 | 矩阵乘法计算量估算
#include <iostream> #include <vector> #include <stack> using namespace std; int main() { int n; cin >> n; vector&...
2025-03-05
0
31
题解 | 矩阵乘法
#include <iostream> #include <vector> using namespace std; int main() { int x, y, z; cin >> x >> y >> z; ve...
2025-03-05
0
30
题解 | 成绩排序
由于成绩范围比较小 所以可以直接定义哈希数组 string[101] 成绩作为数组下标 名字作为对应的string值 重复的名字直接用空格拼接起来最后再拆开即可 #include <iostream> #include <vector> #include <sstrea...
2025-03-04
0
34
题解 | 24点游戏算法
注意的点是for (int j = 0; j < nums.size() && j != i; ++j)并不和for (int j = 0; j < nums.size(); ++j) if (i == j) continue; 等价 因为前者遇到j等于i就直接终止for...
2025-03-03
0
40
题解 | 配置文件恢复
#include <iostream> #include <vector> #include <sstream> using namespace std; bool is_matched(string s, string t) { for(int i =...
2025-03-03
0
38
题解 | 查找两个字符串a,b中的最长公共子串
#include <iostream> using namespace std; int main() { string s, t; cin >> s >> t; if(s.size() < t.size()) swap(s, t)...
2025-03-03
0
56
题解 | MP3光标位置
#include <iostream> #include <vector> using namespace std; int main() { int num; string commands; cin >> num >> c...
2025-02-28
0
37
题解 | DNA序列
#include <iostream> using namespace std; int main() { string gene; int length; cin >> gene >> length; int count_CG ...
2025-02-28
0
38
题解 | 查找输入整数二进制中1的个数
#include <iostream> #include <bitset> using namespace std; int main() { int n, m; cin >> n >> m; int count1 = 0, ...
2025-02-27
0
33
首页
上一页
1
2
3
4
5
6
7
8
9
下一页
末页