一只菜弱鸡
一只菜弱鸡
全部文章
分类
未归档(3)
题解(60)
归档
标签
去牛客网
登录
/
注册
一只菜弱鸡的博客
全部文章
(共65篇)
矩阵的最大值
/* 给定一个仅包含0和1的n*n二维矩阵 请计算二维矩阵的最大值 计算规则如下 1、每行元素按下标顺序组成一个二进制数(下标越大约排在低位), 二进制数的值就是该行的值,矩阵各行之和为矩阵的值 2、允许通过向左或向右整体循环移动每个元素来改变元素在行中的位置 比如 [1,0,1,1,1] 向右...
C++
2022-05-02
1
791
两个班的小朋友混在一起,找出同班的小朋友。
/* 幼儿园两个班的小朋友排队时混在了一起 &n...
2022-05-02
1
1206
题解 | #整型数组合并#
/*set容器自动去重,并按照升序排列*/ #include <set> #include <iostream> using namespace std; int n1,n2,tmp; set<i...
C++
2022-04-28
1
322
题解 | #查找组成一个偶数最接近的两个素数#
#include <bits/stdc++.h> using namespace std; int n; int i,j; bool isprime(int a){ //判断一个数是不是...
C++
2022-04-28
6
336
题解 | #从单向链表中删除指定值的节点#
#include <algorithm> #include <iostream> #include <list> using namespace std; int n,head,after,front,a...
C++
2022-04-28
0
366
题解 | #参数解析#
正则表达式,没学会怎么匹配但不捕获,所以只能正则了两遍。 #include<regex> #include<iostream> using namespace std; string str; int cnt = ...
C++
2022-04-28
0
331
题解 | #Redraiment的走法#
/*最长升序列*/ #include<iostream> using namespace std; int n; //序列长度 int a[201]; //从1开始存储数据 int...
C++
2022-04-27
0
363
题解 | #计算日期到天数转换#
#include <iostream> using namespace std; int a[13] = {0,31,28,31,30,31,30,31,31,30,31,30,31}; int OrdYeardays...
C++
2022-04-27
0
278
题解 | #字符串字符匹配#
#include <iostream> #include <algorithm> using namespace std; string Match(string str1, string st...
C++
2022-04-27
0
241
题解 | #公共子串计算#
#include <bits/stdc++.h> using namespace std; int maxlen(string str1, string str2) { ...
C++
2022-04-27
0
292
首页
上一页
1
2
3
4
5
6
7
下一页
末页