c++ 公倍数 公约数 摘要:解题思路:求最小公倍数:从(两数中的较大值,到两数相乘的值)逐个遍历,如果两个数都能被整除则输出,并且退出遍历,因为是从小到大遍历,所以输出的公倍数是最小的。因为所有输入中最小公倍数最小可能是a(两数…… 题解列表 2022年05月12日 0 点赞 0 评论 362 浏览 评分:9.9
宏定义和函数找最大值 摘要:解题思路:用三目运算符非常简单注意事项:参考代码:#include<iostream>#include<iomanip>using namespace std;#define max(a,b,c) (…… 题解列表 2022年05月12日 0 点赞 0 评论 239 浏览 评分:0.0
九九乘法表 摘要:解题思路:注意事项:参考代码:#include<iostream>#include<iomanip>using namespace std;int main(){ for (int i = 1; i …… 题解列表 2022年05月12日 0 点赞 0 评论 317 浏览 评分:0.0
欧几里得法求最大公倍数,最小公约数 摘要:解题思路:注意事项:参考代码://辗转相除法 #include<iostream>using namespace std;int gcd(int a,int b){ if(a%b==0) retur…… 题解列表 2022年05月12日 0 点赞 0 评论 253 浏览 评分:0.0
C++处理数字位数与输出 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int a,b[5],c; cin >> a; if (a / 100…… 题解列表 2022年05月12日 0 点赞 0 评论 237 浏览 评分:0.0
求矩阵的两对角线上的元素之和 摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;long long n,a[15][15],s,t;int main(){ cin>…… 题解列表 2022年05月12日 0 点赞 0 评论 217 浏览 评分:0.0
蓝桥杯算法提高VIP-淘淘的名单 题解(c++判断简单题) 摘要:解题思路:三步完事:输入,判断,输出。注意事项:无。参考代码:#include<bits/stdc++.h>using namespace std;string s;int n;int main(){…… 题解列表 2022年05月12日 0 点赞 0 评论 288 浏览 评分:9.9
蓝桥杯算法提高VIP-格式化数据输出 题解(c++ 坑人题目) 摘要:解题思路:坑人的格式化输出!!!!!害得我错了好几次!!!上题解!注意事项:无。参考代码:#include<bits/stdc++.h>using namespace std;int main(){ …… 题解列表 2022年05月12日 0 点赞 0 评论 202 浏览 评分:0.0
蓝桥杯算法提高VIP-数组输出 题解(c++ 哎!没办法) 摘要:解题思路:错的次数太多了,我也无语了,直接理解吧!呵呵!上代码!注意事项:无。参考代码:#include<bits/stdc++.h>using namespace std;int a[5][5],x…… 题解列表 2022年05月12日 0 点赞 0 评论 187 浏览 评分:0.0
蓝桥杯算法提高VIP-复数求和 题解(c++我有重大发现!!!!!) 摘要:解题思路:这里更正一下啊,这里的链表在c++中也叫结构体。怪不得我在题目标签里找不到结构体!直接上程序!注意事项:无。参考代码:#include<bits/stdc++.h>using namespa…… 题解列表 2022年05月12日 0 点赞 0 评论 220 浏览 评分:0.0