wrdoct
wrdoct
全部文章
复习
面经(1)
题解(88)
归档
标签
去牛客网
登录
/
注册
wrdoct的博客
全部文章
/ 复习
(共44篇)
题解 | #24点游戏算法#
#include <bits/stdc++.h> using namespace std; double num = 1e-6; int ANS = 24; int ADD = 0, SUB = 1, MUL = 2, DIV = 3; bool process(vector<...
C++
2022-05-26
0
289
题解 | #统计每个月兔子的总数#
#include <bits/stdc++.h> using namespace std; int process(int n){ return n < 3 ? 1 : process(n - 1) + process(n - 2); } int main(){ ...
C++
2022-05-20
0
223
题解 | #蛇形矩阵#
#include <bits/stdc++.h> using namespace std; void process(int N){ /*if(N == 0){ cout << "" << endl; }*/ //第一行...
C++
2022-05-17
0
255
题解 | #密码截取#
#include <bits/stdc++.h> using namespace std; int getLength(string str, int l, int r){ while(l >= 0 && r < str.size() &&...
C++
2022-05-17
0
276
题解 | #设计LRU缓存结构#
struct DoubleLinkedNode{ int key; int value; DoubleLinkedNode* prev; DoubleLinkedNode* next; DoubleLinkedNode() : key(0), value(0), pr...
C++
2022-05-15
0
283
题解 | #密码验证合格程序#
#include <bits/stdc++.h> using namespace std; //包括大小写字母.数字.其它符号,以上四种至少三种 bool checkChar(string str){ int i = 0, j = 0, k = 0, l = 0; f...
C++
2022-05-11
0
302
题解 | #合唱队#
#include <bits/stdc++.h> using namespace std; void process(vector<int> vec, int N, int& res){ vector<int> leftNum(N, 0); ...
C++
2022-05-11
0
246
题解 | #识别有效的IP地址和掩码并进行分类统计#
//#include <bits/stdc++.h> #include <iostream> #include <string> #include <sstream> #include <vector> using namespace s...
C++
2022-05-10
0
436
题解 | #坐标移动#
#include <bits/stdc++.h> #include <iostream> #include <string> using namespace std; unordered_map<char, pair<int, int>>...
C++
2022-05-07
0
254
题解 | #24点运算#
#include <iostream> #include <string> #include <unordered_map> #include <vector> #include <algorithm> using namespace s...
C++
2022-05-05
0
324
首页
上一页
1
2
3
4
5
下一页
末页