回文串-字符串处理(C++) 摘要:参考代码:#include<cstdio>#include<cstring>const int maxn = 256; //判断字符串str是否是“回文串”bool judge(char str[…… 题解列表 2023年01月23日 0 点赞 0 评论 338 浏览 评分:0.0
详解,注释多,易理解 摘要:要注意转换的顺序,比如数据10 2 3 4 5 6 7 8 1 9,如果直接找到最大值最小值所在位置的下标,再互换会出错,所以我选择分先后转换,先转换最小值和第一个数字,再转换最大值和最后一个数字 …… 题解列表 2023年01月21日 0 点赞 0 评论 325 浏览 评分:0.0
1726: 字符串的反码 摘要:解题思路:根据题意可得,b的反码是x 即b-a==z-x x==z+a-b 即s[i]的反码为z+a-s[i]注意测试数据内有空格,代码需要可以接收空格参考代码:#include <iostream>…… 题解列表 2023年01月21日 1 点赞 0 评论 468 浏览 评分:9.9
1273: ISBN码(简介代码) 摘要:解题思路:先解释一下题目,要求检查识别码是否正确,识别码是最后一位的数字0-670-82162-4,这里最后一位的4就是识别码。4=(0×1+6×2+……+2×9)%11;注意如果最后得10,识别码为…… 题解列表 2023年01月21日 0 点赞 0 评论 393 浏览 评分:9.9
1503: 蓝桥杯算法提高VIP-前10名(简洁代码) 摘要:解题思路:用头文件algorithm中的sort函数注意事项:参考代码:#include<iostream>#include<algorithm>using namespace std;int mai…… 题解列表 2023年01月21日 0 点赞 0 评论 277 浏览 评分:0.0
排序(超简单的sort排序) 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int arr[200000]={0};int main(){ int n; wh…… 题解列表 2023年01月20日 0 点赞 0 评论 375 浏览 评分:0.0
数据结构-快速排序 摘要:解题思路:注意事项:参考代码: #include<bits/stdc++.h>using namespa…… 题解列表 2023年01月20日 0 点赞 0 评论 387 浏览 评分:0.0
1477: 字符串输入输出函数 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<iomanip>#include<string>using namespace std;int shu(string…… 题解列表 2023年01月20日 0 点赞 0 评论 327 浏览 评分:0.0
1470: 蓝桥杯基础练习VIP-时间转换 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ long long n; while(cin>>n){ int a…… 题解列表 2023年01月20日 0 点赞 0 评论 276 浏览 评分:0.0
1069: 二级C语言-寻找矩阵最值 摘要:解题思路:使用下标记录最大值位置,在对比时使用数组和下标,这样可以少写一个储存最大值的变量使用abs函数,简化代码参考代码:#include <iostream> #include <cmath> …… 题解列表 2023年01月20日 0 点赞 0 评论 433 浏览 评分:9.9