题解 1738: 排序

来看看其他人写的题解吧!要先自己动手做才会有提高哦! 
返回题目 | 我来写题解

筛选

1738: 排序 (sort)

摘要:解题思路:使用sort()排序,注意使用头文件<bits/stdc++.h>或使用#include<algorithm>头文件sort(begin, end, cmp),其中b……

这个代码简单些

摘要:解题思路:注意事项:可以输入输出多组数据,列题有误导,所以要加上跳出条件参考代码:while True: try: n=……

三种方法:sort()+multiset容器+递归函数

摘要:解题思路:注意事项:注意题目说可能有多组测试数据,所以要使用循环输入,我就是刚开始没注意,根本不知道自己代码哪里出问题了-_-参考代码://sort()#include<iostream>……

1738: 排序 冒泡排序

摘要:解题思路:注意事项:参考代码:#include<iostream>#include<iomanip>#include<cmath>using namespace s……

排序(超简单的sort排序)

摘要:解题思路:注意事项:参考代码:#include<bits/stdc++.h>using namespace std;int arr[200000]={0};int main(){  int n; wh……

 编写题解 1738: 排序

摘要:解题思路:注意事项:参考代码:#include<iostream>using namespace std;#include<vector>#include<algorithm>void print(v……

冒泡法排序(c语言)

摘要: #include <stdio.h> int main() {     int n, a[123], i, j, t;       while (scanf("%d", &n) !=……

题解 1738: 排序

摘要:解题思路:冒泡排序我首先定义的就是n,然后定义数组,输入,判断n对数据进行排序时需要两个变量i,j,不断遍历,每一次循环确定一个位置最后输出注意事项:我考虑了n的大小,冒泡排序的变量,可是一直出现错误……