题解列表

筛选

编写题解 1159: 偶数求和

摘要:解题思路:分奇偶情况讨论注意事项:输出次数的计算参考代码:#include<iostream>using namespace std;int main(){    int n, m;    while……

[归并排序]数组法(c++)

摘要:解题思路:先分别将两个数组各自排序,再使用归并排序注意事项:参考代码:#include <iostream>using namespace std;int main() { int n, m, t; ……

DNA简单题解

摘要:#include<iostream>using namespace std;struct DNA{    int a;//行数    int b;//重复度};int main(){    int n……

巧用sort解题

摘要:解题思路: 1、首先要创建两个链表,并且给数值域赋值;               2、重要的是排序,STL里有sort函数能对结构体进行排序,因为是链表,无法调用sort排序            ……

C++蛇行矩阵

摘要:解题思路:找到每个数与行数、列数的关系注意事项:注意每个数与行数、列数的关系参考代码:#include<iostream>using namespace std;int main(){    int ……