题解列表

筛选

数列排序(C++)

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

1071: 二级C语言-阶乘公式求值

摘要:注意 fact 函数的返回值类型是 double。(不是 double 的话 100 的测试值无法通过)#include<bits/stdc++.h> using namespace std;  ……

1067: 二级C语言-分段函数

摘要:#include<bits/stdc++.h> using namespace std;   int main() {     double x;     cin >> x;     if……

1017: [编程入门]完数的判断

摘要:思路是从 1 到 n 挨个处理,保存其所有因数(除了自身),最后所有因数和与自身比较,如果相等则为完数。#include<bits/stdc++.h> using namespace std;  ……

日期排序(C++) multiset

摘要:解题思路:注意事项:参考代码:#include<iostream> #include<cstdio> #include<set> #include<string> using namespac……

1051: [编程入门]结构体之成绩统计2

摘要:先把数据读进来,然后遍历所有学生数据,保存最高分学生数据,分别保存所有学生三科成绩,输出时使用了accumulate()函数。#include<bits/stdc++.h> using namesp……