C++代码用C++风格输出%6.2f格式的浮点数 摘要:解题思路:用C++风格输出%6.2f格式的浮点数https://blog.csdn.net/jal517486222/article/details/84591515注意事项:暂时不明参考代码:#in…… 题解列表 2021年12月28日 1 点赞 0 评论 823 浏览 评分:0.0
C++函数,宏定义找3个数的最大数 摘要:解题思路:选择法排序if (a<b) a=b;if (a<c) a=c;return a;注意事项:暂时不明参考代码:#include<iostream>#include<iomanip>using …… 题解列表 2021年12月28日 0 点赞 0 评论 492 浏览 评分:0.0
C++代码String库函数 摘要:解题思路:注意事项:暂时不明参考代码:#include<iostream>#include<string>using namespace std;int main(){ string origi…… 题解列表 2021年12月28日 0 点赞 0 评论 503 浏览 评分:0.0
C++代码宏定义实参实现2个数字交换,最终实现3个数字的排序 摘要:解题思路:选择排序法注意事项:暂时不明参考代码:#include<iostream>using namespace std;#define swap(x,y) {int temp=x;x=y;y=te…… 题解列表 2021年12月28日 0 点赞 0 评论 365 浏览 评分:0.0
解 1635: 蓝桥杯算法训练VIP-整数平均值 摘要:解题思路:注意事项:参考代码: n = int(input()) s = list(map(int,input().split())) print(int(sum(s)/len(s)))…… 题解列表 2021年12月29日 0 点赞 0 评论 518 浏览 评分:0.0
编写题解 1670: 拆分位数 摘要:解题思路:注意事项:参考代码: a= input() for i in a[::-1]: print(i,end=' ')…… 题解列表 2021年12月29日 0 点赞 0 评论 490 浏览 评分:0.0
编写题解 1671: 小九九 摘要:for i in range(1,10): for j in range(1,i+1): print('%-6s'%(f'{j}*{i}={i*j}…… 题解列表 2021年12月29日 0 点赞 0 评论 556 浏览 评分:0.0
利用笨办法求解 摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int main(){ int a; int b; while (cin >> a) { …… 题解列表 2021年12月29日 0 点赞 0 评论 435 浏览 评分:0.0
C++代码纯手写,采用实参宏定义函数交换2个字符串。字符串两两比较,自定义函数for循环,遍历实现字符串逐位比较,返回大小比较结果,立刻交换即可。保证str1<=str2<=str3 摘要:也许会有朋友说写那么复杂干什么,直接调用一个库函数进行比较多方便。一些基本但复杂的东西,C/C++的乐趣就在此。用python直接调用库函数最简洁。解题思路:C++代码纯手写,采用实参宏定义函数交换2…… 题解列表 2021年12月29日 0 点赞 0 评论 854 浏览 评分:0.0
1772: [编程入门]二进制移位练习 摘要:解题思路:注意事项:参考代码:def two_to_ten(m): j = 0 sum =0 for i in str(m)[::-1]: sum +=…… 题解列表 2021年12月29日 1 点赞 0 评论 481 浏览 评分:0.0