题解 1219: 数列排序

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

筛选

数列排序 (C语言代码)

摘要:解题思路:注意事项:参考代码:#include<stdio.h>int main(){ int n,a[10],i,j,k; scanf("%d",&n); while(n--) {  int b[1……

数列的排列~~~

大致思路:先找比a[0]小的元素放入一个数组,记录数量l;再找比a[0]大的元素放入一个数组,记录数量m;最后将比a[0]小的元素逆置输出,a[0]的位置就在a[l],比a[0]大的元素数组正常输出#includeintmain(){intn;scanf("%d",

数列排序C++

摘要:解题思路:注意事项:参考代码:#include <iostream>using namespace std;int a[1000000], b[1000000];int main(){ int n; ……

数列排序 (Java代码)

摘要:解题思路:注意事项:参考代码:public class 数列排序 { public static void main(String[] args) { // TODO Auto-gene……

数列排序 (C++代码)

摘要:解题思路:注意事项:参考代码:#include<iostream> using namespace std; int main() { int n; cin>>n; while(n-……

1219: 数列排序

摘要:解题思路:观察输出,发现比第一位小的排序是靠右的排在前面,所以先从最后面开始遍历数组,找到比第一位小的就打印出来,然后再打印比第一位大的数参考代码:#include <stdio.h> int ……

数列排序python

摘要:解题思路:注意事项:比第一个数字小的在左边,大的在右边,但并没有排序参考代码:n = int(input())for i in range(n):    L = list(map(int,input(……

1219: 数列排序

```cpp#include#include#includeusingnamespacestd;intmain(){std::ios::sync_with_stdio(0);cin.tie(0);vectorv1;stacks1;intn,s;cin>>n;while(n--){for(inti=0;