题解列表

筛选

手写一个快速排序算法

摘要:解题思路:快速排序算法注意事项:多关键字比较参考代码:#include <stdio.h> typedef struct _Point {     int x, y, z; } Point;……

威佐夫博弈论罢了

摘要:```cpp #include using namespace std; signed main(){ int a = 0, b = 0; while (cin>>a>……

最匹配矩阵

摘要:解题思路:注意事项:参考代码:#include<iostream>#include<vector>#include<utility>using namespace std;int Difference……

STL deque优雅方案

摘要:解题思路:使用STL队列维护m个连续奇数注意事项:参考代码:#include<iostream> #include<cmath> #include<deque> using namespace ……

2990: 十进制到八进制

摘要:解题思路:注意事项:参考代码:import java.lang.*; import java.math.BigDecimal; import java.util.Scanner; pub……

2821: 开关灯

摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>typedef long long ll;const int N=1e5;ll a[N];using namespace s……

课后1002三个数最大值的求解方法

摘要:解题思路:条件表达式1、条件运算符。它是一个三目运算符,由?:组成。2、条件表达式。由条件运算符组成条件表达式。一般形式为:表达式1?表达式2:表达式3其求值规则是:如果表达式1的值为真,则以表达式2……

最简单的做法

摘要:解题思路:使用set容器注意事项:参考代码:#include <bits/stdc++.h> using namespace std; const int N=10100; stri……