2853: 字符替换 摘要:解题思路:将字符串和字符存储下来后,再通过循环把字符串反复判断并改为题目要求的字符注意事项:循环内需要i从0开始循环,并用strlen()函数把数组最后的值的下标求出,放入循环参考代码:#includ…… 题解列表 2024年07月19日 0 点赞 0 评论 287 浏览 评分:0.0
1119: C语言训练-"水仙花数"问题1 摘要:解题思路:1,倒序。 g = n % 10;%10的结果是他的个位,个位我们用g表示。 n = n / 10;/10是剩下的数。 fn = fn + g * g * g;这是倒序后…… 题解列表 2024年07月19日 0 点赞 0 评论 288 浏览 评分:0.0
1720: 数据结构-基数排序 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;const int N=1e5;ll a…… 题解列表 2024年07月20日 0 点赞 0 评论 310 浏览 评分:0.0
2917: 奇数单增序列 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;const int N=1e3;ll a…… 题解列表 2024年07月20日 0 点赞 0 评论 463 浏览 评分:0.0
计算分数的浮点数值 摘要:解题思路:注意事项:保留九位小数,注意被除数不能为零参考代码:a,b = map(int,input(().split()) if b != 0: result = round(a/b,9) …… 题解列表 2024年07月21日 0 点赞 0 评论 816 浏览 评分:0.0
2883: 矩阵加法 摘要:解题思路:注意事项:参考代码:#include <bits/stdc++.h>using namespace std;typedef long long ll;const ll N=1e3;ll a[…… 题解列表 2024年07月21日 0 点赞 0 评论 292 浏览 评分:0.0
用快读scanf别用cin 摘要:解题思路:/*带权并查集模板*/注意事项:参考代码:#include<bits/stdc++.h>typedef long long ll;using namespace std;int fa[100…… 题解列表 2024年07月21日 0 点赞 0 评论 379 浏览 评分:0.0
判断数正负 摘要:解题思路:注意事项:参考代码:N = int(input())if N > 0: print("positive")elif N == 0: print("zero")elif N < 0…… 题解列表 2024年07月22日 0 点赞 0 评论 560 浏览 评分:0.0
vector写数组 摘要:#include<bits/stdc++.h> using namespace std; int main() { int n; cin>>n; vector<in…… 题解列表 2024年07月22日 0 点赞 0 评论 251 浏览 评分:0.0