Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"sort"
	"strconv"
)

var scanner = bufio.NewScanner(os.Stdin)

func nextString() string {
	scanner.Scan()
	return scanner.Text()
}

func nextInt() int {
	n, err := strconv.Atoi(nextString())
	if err != nil {
		fmt.Printf("strconv.Atoi failed: %v\n", err)
	}
	return n
}

func main() {
	scanner.Split(bufio.ScanWords)

	n := 5
	array := make([]int, n)
	for i := 0; i < n; i++ {
		array[i] = nextInt()
	}
	sort.Slice(array, func(i, j int) bool { return array[i] > array[j] })
	arrayStr := fmt.Sprint(array)
	l := len(arrayStr)
	fmt.Println(arrayStr[1:(l - 1)])
}

C++: #include<iostream>
#include<algorithm>

using namespace std;

int main(){
	
	int ary[5];

	for (int i = 0; i < 5; i++){
		cin >> ary[i];
	}

	for (int i = 0; i < 5; i++){
		for (int j = i + 1; j < 5; j++){
			if (ary[i] < ary[j]){
				swap(ary[i], ary[j]);
			}
		}
	}

	for (int i = 0; i < 5; i++){
		cout << ary[i];
		if (i != 4)
			cout << ' ';
	}

	cout << endl;

	return 0;
}

C++: #include <iostream>
#include <algorithm>

using namespace std;

int v[5];

int main(void) {
    for(int i = 0; i < 5; i++) {
        cin >> v[i];
    }

    sort(v, v + 5);
    reverse(v, v + 5);

    for(int i = 0; i < 4; i++) {
        cout << v[i] << " ";
    }
    cout << v[4];
    return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <iterator>
#include <functional>

#define REP(i,n) for(int i = 0; i < (n); ++i)
using namespace std;

int main(){
	vector<int> ret;
	int a;
	while(cin>>a) ret.push_back(a);
	sort(ret.begin(), ret.end() ,greater<int>());
	REP(i, ret.size()) {
		cout<<ret[i];
		if (i != ret.size() -1)
		{
			cout << " ";
		}
	}
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

	int a[5];
	for(int i = 0; i < 5; i++)
		cin>>a[i];
	
	sort(a,a+5,greater<int>());
	
	for(int i = 0; i < 5; i++){
		cout<<a[i];
		if(i==4)
			cout<<endl;
		else
			cout<<" ";
	}

	return 0;
}

C++: #include <algorithm>
#include <iostream>

int main(void) {
  int ary[5], i;

  for (i = 0; i < 5; i++) {
    std::cin >> ary[i];
  }

  std::sort(ary, ary + 5, std::greater<int>());

  for (i = 0; i < 5; i++) {
    std::cout << ary[i];

    if (i == 4) {
      std::cout << std::endl;
    } else {
      std::cout <<  " ";
    }
  }

  return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

int main() {
	int num[5];
	for (int i = 0; i < 5; ++i) {
		cin >> num[i];
	}

	sort(num, num + 5);

	for (int i = 4; i >= 0; --i) {
		cout << num[i] << " ";
	}
	cout << endl;
}

C++:  #include<stdio.h>
#include<algorithm>
using namespace std;

int main()
{

    int a[100],n=5;
    int temp =0;

    for(int i=0;i<n;i++)
    {
        scanf("%d",&a[i]);
    }



    for(int i=0;i<n-1;i++)
    {
        for(int j=i+1;j<n;j++)
        {
            if(a[i]<a[j])
            {

              swap(a[i],a[j]);

            }
        }
    }

    for(int i=0;i<n;i++)
    {
        printf("%d",a[i]);
        if(i<4)
        printf(" ");
        else printf("\n");
    }
    return 0;
}

C++: #include <iostream>
#include <algorithm>

using namespace std;

int main(){
  int a[5];
  while(cin>>a[0]>>a[1]>>a[2]>>a[3]>>a[4]){
    sort(a,a+5);
    cout<<a[4]<<" "<<a[3]<<" "<<a[2]<<" "<<a[1]<<" "<<a[0]<<endl;
  }
}

C++: // 失敗するからこそ そこから立ち向かって行く強さがあってそんな強さが本当の強さだと私は思うから
#ifdef DAIJOBU
#include "/home/v-o_o-v/deb.h"
#define deb(x...) cerr << "[" << #x << "] = ["; _print(x)
#else
#include <bits/stdc++.h>
#define deb(x...)
#endif 

using namespace std;

int main() {
	ios::sync_with_stdio(0);
	cin.tie(0);

	vector<int> v;
	for(int i = 0; i < 5; i++){
		int a;
		cin >> a;
		v.push_back(a);
	}
	sort(v.rbegin(), v.rend());
	int cas = 1;
	for(auto i:v){
		if(cas > 1)cout << ' ';
		cas++;
		cout << i;
	}
	cout << '\n';
	return 0;
}
// Write Here

C++: #include<iostream>
#include<algorithm>
using namespace std;
int main()
{
	int a[5];
	for (int i = 0; i < 5; i++){
		cin >> a[i];
	}
	sort(a, a + 5);
	for (int i = 4; i > 0; i--){
		cout << a[i] << " ";
	}
	cout << a[0]<<endl;
}

C++: #include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

int main(){
	int n;
	int c=0;
	vector<int> buf;
	while(cin>>n){
		c++;
		buf.push_back(n);
		if(c==5){
			sort(buf.begin(),buf.end());
			reverse(buf.begin(),buf.end());
			for(int i=0; i<buf.size(); i++){
				if(i!=0) cout<<" ";
				cout<<buf[i];
			}
			cout<<endl;
			buf.clear();
			c = 0;
		}
	}
	return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <functional>

using namespace std;

int main(){
  int a[5];
  for(int i=0;i<5;i++) cin >> a[i];
  sort(a,a+5,greater<int>());
  for(int i=0;i<5;i++) cout << a[i] << (i==4?"\n":" ");
  return 0;
}

C++: #include<cstdio>
#include<iostream>
#include<cstring>
#include<string>
#include<algorithm>

using namespace std;

int main()
{
    int arr[5+10];
    for(int i=0;i<5;i++)
        cin>>arr[i];
    sort(arr,arr+5);
    for(int i=4;i>=0;i--)
    {
          cout<<arr[i]<<" ";
    }
    cout<<endl;


return 0;
}

C++: #include <stdio.h>
int main ()
{
    int a[6],i,m,k;
    for (i=0;i<5;i++)
        scanf("%d",&a[i]);
    for (i=0;i<5;i++)
    {
        for (m=i+1;m<5;m++)
        {
            if (a[i]<a[m])
            {
                k=a[i];
                a[i]=a[m];
                a[m]=k;            
            }
            
        }
    }
    for (i=0;i<5;i++)
        printf("%d " , a[i]);
    return 0;
}

C++: #include<iostream>
#include<string>
#include<algorithm>
using namespace std;

int main(){
    int n[5];
    cin>>n[0]>>n[1]>>n[2]>>n[3]>>n[4];
    sort(n,n+5);
    cout<<n[4]<<" "<<n[3]<<" "<<n[2]<<" "<<n[1]<<" "<<n[0]<<endl;
    return 0;
}

C++: #include<iostream>

int main(){
	int a[5],i,j,n;
	for(i=0;i<5;i++){
	std::cin>>a[i];
	}
	for(i=0;i<4;i++){
		for(j=i+1;j<5;j++){
			if(a[i]<a[j]){
			n=a[i];
			a[i]=a[j];
			a[j]=n;
			}
		}
	}
	for(i=0;i<5;i++){
	std::cout<<a[i]<<std::endl;
	}
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <algorithm>
#include <functional>

using namespace std;

void solve()
{
	vector<int> Num(5);
	for(int i = 0; i < 5; ++i)
	{
		cin >> Num[i];
	}
	sort(Num.begin(), Num.end(), greater<int>() );
	for(int i = 0; i < 5; ++i)
	{
		cout << Num[i] << " ";
	}
	cout << endl;
}

int main()
{
	solve();
	return(0);
}

C++: #include<iostream>
using namespace std;

int main(){
    int a = 0, b = 0, c = 0, d = 0, e = 0, poi[5];
    for(int i = 0;i < 5;++i) cin >> poi[i]; 
    for(int j = 0;j < 5;++j){
       if(poi[j] > a){
        e = d;
        d = c;
        c = b;
        b = a;
        a = poi[j];
        }
       else if(poi[j] > b){
        e = d;
        d = c;
        c = b;
        b = poi[j];
        }
       else if(poi[j] > c){
        e = d;
        d = c;
        c = poi[j];
        }
       else if(poi[j] > d){
        e = d;
        d = poi[j];
        }  
       else d = poi[j];
    } 
    cout << a << " " << b << " " << c << " " << d << " " << e << endl;
    return 0;
}

C++: #include <iostream>
#include <algorithm>
using namespace std;

int main(void){
  int a[5] = {0};
  for(int i = 0;i<5;i++) cin >> a[i];
  sort(a,a+5, [](const int& a, const int& b){
    return a > b;
  });
  for(int i = 0;i<5;i++){
    if(i != 0) cout << " ";
    cout << a[i];
    if(i == 4) cout << endl;
  }
}

C++: #include <iostream>
#include <utility>
using namespace std;

int main()
{
    ios::sync_with_stdio(false);
    cin.tie(0);
    int a[5];
    cin>>a[0]>>a[1]>>a[2]>>a[3]>>a[4];
    for(int i=4; i>=0; i--) {
        for(int j=0; j<i; j++) {
            if(a[j]<a[j+1]) swap(a[j], a[j+1]);
        }
    }
    cout<<a[0]<<' '<<a[1]<<' '<<a[2]<<' '<<a[3]<<' '<<a[4]<<'\n';
    return 0;
}