[编程入门]三个数字的排序 冒泡排序 摘要:参考代码:#include<stdio.h>int main(){ int a[3]; for(int i=0;i<3;i++) scanf("%d",&a[i]); for(int j=0;…… 题解列表 2022年01月05日 0 点赞 0 评论 344 浏览 评分:0.0
python 一行代码 摘要:参考代码: print(" ".join(str(i) for i in(sorted(list(map(int,input().split()))))))用了三个python内置函数以及迭代输出…… 题解列表 2021年12月29日 0 点赞 0 评论 630 浏览 评分:9.9
C++代码宏定义实参实现2个数字交换,最终实现3个数字的排序 摘要:解题思路:选择排序法注意事项:暂时不明参考代码:#include<iostream>using namespace std;#define swap(x,y) {int temp=x;x=y;y=te…… 题解列表 2021年12月28日 0 点赞 0 评论 280 浏览 评分:0.0
三个数字的排序-冒泡/选择排序法 摘要:解题思路:冒泡法与选择法排序注意事项:参考代码:#include <stdio.h>int main(){ int i,j,t,a[3]; //定义变量及数组为基本整型 //prin…… 题解列表 2021年12月11日 0 点赞 0 评论 460 浏览 评分:0.0
编写题解 1043: [编程入门]三个数字的排序 摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;int main(){ int a,b,c; cin>>a>>b>>c; i…… 题解列表 2021年12月09日 0 点赞 0 评论 333 浏览 评分:0.0
编写题解 1043: [编程入门]三个数字的排序 摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int a,b,c,t; scanf("%d %d %d",&a,&b,&c); if(a>b…… 题解列表 2021年12月05日 0 点赞 0 评论 324 浏览 评分:0.0
降序输出3个数 摘要:解题思路:3个变量依次比较就行了注意事项:参考代码:# include <stdio.h>int main () {int a,b,c,t; scanf ("%d %d %d",&a,&b,&c); …… 题解列表 2021年12月04日 0 点赞 0 评论 402 浏览 评分:0.0
冒泡排序法 摘要:解题思路:首先我们看到这个题时应该会想起冒泡排序,那么我们就可以尝试用数组来储存数值,利用for循环输入元素,之后利用冒泡排序对元素进行排序,最后利用for循环来输出排序后的数值。注意事项:冒泡排序时…… 题解列表 2021年11月26日 0 点赞 0 评论 512 浏览 评分:0.0
排序(C语言自己的排序函数) 摘要: #include #include //C语言自己的排序函数为qsort(),内部运用的是快速排序机制 int comp(const void *a,co…… 题解列表 2021年11月18日 0 点赞 0 评论 497 浏览 评分:0.0
三个数字的排序 摘要:解题思路:注意事项:参考代码:int a[3],j,k,l; for(j=0;j<3;j++) scanf("%d",&a[j]); for(j=1;j<3;j++) for(…… 题解列表 2021年11月16日 0 点赞 0 评论 336 浏览 评分:0.0