题解列表
1136求具有abcd=(ab+cd)2性质的四位数(直接输出那三个数)
摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cmath>using namespace std;int main(){ for (int i = 1000; i……
1135求s=a+aa+aaa+aaaa+aa...a的值(while循环)
摘要:解题思路:注意事项:参考代码:#include<iostream>#include<cmath>using namespace std;int main(){ int a, n; cin >> a >……
1134求PI*(while循环)
摘要:解题思路:注意事项:答案是3.141591参考代码:#include<iostream>using namespace std;int main(){ double a = 1.0;//这是分子 do……
1133阶乘的和(简单的动态规划)
摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int n; cin >> n; long long arr[25] ……
1132最大数问题(while循环解决)
摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int a; cin >> a; int b; if (a == -1……
1101: 循环 高精度
摘要:解题思路:规律:当后K为数字存在循环结的必要条件是,后K-1位数字存在循环结,并且K的最小循环结必定是K-1的最小循环结的整数倍。并且对于当前位数的处理不必要取模,既然已经用了数组高精度保存便可以只考……
蓝桥杯2024年第十五届决赛真题-数位翻转
摘要:解题思路:这道题目可以用动态规划来解决,主要步骤如下:1.定义状态:dp[i][j][0] 表示前 i 个数中恰好选择 j 个区间,且第 i 个数没有翻转时的最大和。dp[i][j][1] 表示前 i……
吐槽这道题!在写交换函数时,先写交换小的是错的?!
摘要:解题思路:注意事项:参考代码:#include<iostream>#include<iomanip>using namespace std;void in(int a[]){for(int i=0;i……