题解列表

筛选

明明的随机数- 排序+ 双指针

摘要:解题思路:排序 + 双指针注意事项:参考代码:#include<iostream> #include<algorithm> using namespace std; const int N = ……

1164: 数组的距离- 极简

摘要:解题思路:双指针算法注意事项:参考代码:#include<iostream> #include<cmath> using namespace std; const int N = 1e3 + 1……

1163: 排队买票()

摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; const int N = 11; long long a[N]; //计算卡特兰……

2915: 接水问题

摘要:解题思路:注意事项:参考代码:#include <stdlib.h> #include <stdio.h> #include <iostream> #include <string.h> us……

1162: 密码(遍历)

摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int main() { int m,cnt = 0; string s, ……

1161: 回文数(高精度)

摘要:解题思路: 高精度求和注意事项:参考代码:#include<iostream> using namespace std; const int N = 1e3 + 10; int a[N],b[N……

2914: 铺地毯

摘要:解题思路:注意事项:参考代码:#include <stdlib.h> #include <stdio.h> #include <iostream> #include <string.h> us……

1160: 出圈 (vector , 公式法)

摘要:解题思路:Vector注意事项:删除元素的位置在末尾的时候,需要注意初始化为0参考代码:#include#include  using namespace std; int main() { ……

1159: 偶数求和

摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int main() { int n, m; while(cin >> n ……

1157: 亲和数(C++)

摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int main() { int n; cin >> n; while(……