【C++】【while循环】3017:最小n值 摘要:题目: 3017:编一程序求满足不等式1+1/2+1/3…+1/n>=m的最小n值。其中n,m为正整数。其中m不超过20。 解题思路: 根据题干可知,此题需要使用循环求和,由于循环次数(n)…… 题解列表 2023年12月03日 0 点赞 0 评论 197 浏览 评分:7.5
练练用vector容器解题 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>#include<vector>using namespace std;const int N=10010;int n,su…… 题解列表 2023年12月02日 0 点赞 0 评论 125 浏览 评分:0.0
利用C++完成自由下落的距离计算 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<math.h>using namespace std;int main(void){ int totalHeight…… 题解列表 2023年12月02日 0 点赞 0 评论 221 浏览 评分:0.0
利用·C++编写有规律的数列求和 摘要:解题思路:注意事项:参考代码:#include<iostream>int main(void){ int range; int fenzi=2,fenmu=1; double result=0; s…… 题解列表 2023年12月02日 0 点赞 0 评论 167 浏览 评分:0.0
利用C++完成完数的判断 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;#define max 1000int range,array[max];int main(v…… 题解列表 2023年12月02日 0 点赞 0 评论 132 浏览 评分:0.0
题解 2548: [CSP-J2020] 优秀的拆分 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h> using namespace std; int z[1000000]; int er(long long a) …… 题解列表 2023年12月02日 0 点赞 0 评论 252 浏览 评分:9.9
题解 2901: 查找特定的值 摘要: #include using namespace std; int c,b,d,sum=1; int a[200000]; int main(){ …… 题解列表 2023年12月02日 0 点赞 0 评论 205 浏览 评分:0.0
快速排序(c++代码) 摘要:解题思路:注意事项:参考代码:const int MAX = 10;int arr[MAX];void qsort(int l, int r) { if (l > r)return; int i = …… 题解列表 2023年12月02日 0 点赞 0 评论 142 浏览 评分:0.0
2908: 白细胞计数 摘要:``` #include using namespace std; const int N = 100010; double a[N]; int main(){ double sum =…… 题解列表 2023年12月02日 0 点赞 0 评论 200 浏览 评分:9.9
1669: 求圆的面积 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;int main(){ double r,s; cin>>r; …… 题解列表 2023年12月02日 1 点赞 0 评论 633 浏览 评分:9.9