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>

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

C++: #include<cstdio>
#include<algorithm>
int main(){
    int a[5];
    while(~scanf("%d",&a[0])){
        for(int i=1;i<5;i++){
            scanf("%d",&a[i]);
        }
        std::sort(a,a+5);
        std::reverse(a,a+5);
        for(int i=0;i<5;i++){
            printf("%d ",a[i]);
        }
        printf("\n");
    }
}

C++: #include <iostream>

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

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

int main()
{
	int a[5];

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

	sort(a,a+5,greater<int>());

	for(int i=0; i<5; i++)
	{
		printf("%d",a[i]);
		printf(" ");
	}

	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] << ' ';
  }

  std::cout << std::endl;

  return 0;
}

C++: #include <iostream>
#include <queue>
#include <stack>
#include <vector>
#include <stdio.h>
#include <algorithm>
#include <string.h>
#include <string>
#include <cmath>
#include <complex>
#include <map>
using namespace std;
 
#define rep(i,n) for(int i=0;i<int(n);++i)
 
static const double PI=6*asin(0.5);
typedef complex<double> P;
typedef long long ll;
static const double eps = 1e-8;
 
vector<int> a;
int t;

int main(){
	while(cin>>t){
		a.push_back(t);
	}
	sort(a.begin(),a.end());
	int n=a.size();
	cout<<a[(n--)-1];
	a.pop_back();
	while(!a.empty()){
		cout<<" "<<a[(n--)-1];
		a.pop_back();
	}
	cout<<endl;
	return 0;
}

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

using namespace std;
int main()
{
	int i, j;
	int num[5];
	
	for(i = 0; i < 5; i++)
	{
		cin >> num[i];
	}
	
	stable_sort(num, num + 5, greater<int>());
	
	for(i = 0; i < 5; i++)
	{
		cout << num[i] << " ";
	}
		
		cout << endl;
	
	return 0;
}

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

int number[5];

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

int main(void){
	for(int i = 0; i < 5; i++){
		cin >> number[i];
	}
	bubble();
	for(int i = 0; i < 5; i++){
		cout << number[i];
		if(i != 4)	cout << " ";
	}
	cout << endl;
  return 0;
}

C++: #include<iostream>
#include<algorithm>
#include<stdio.h>

using namespace std;


int main(){

	int x[5];

	for (int i = 0; i < 5; i++){
		cin >> x[i];
		x[i] *= (-1);
	}

	sort(x, x + 5);

	printf("%d %d %d %d %d\n", -x[0], -x[1], -x[2], -x[3], -x[4]);

	return 0;
}

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

int main(){
int a[5];
int biggest[5];
cin>>a[0]>>a[1]>>a[2]>>a[3]>>a[4];
biggest[0]=a[0];
for(int i=1;i<5;i++){
for(int j=0;j<i;j++){
if(a[i]>biggest[j]){
for(int k=i;k>j;k--){
biggest[k]=biggest[k-1];}
biggest[j]=a[i];
break;}}}
cout<<biggest[0]<<" "<<biggest[1]<<" "<<biggest[2]<<" "<<biggest[3]<<" "<<biggest[4];
}

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


int main(void)
{
	int a[5] = {};
	for(int i = 0 ; i < 5 ; i++){
		scanf("%d",&a[i]);
	}
	sort(a,a+5);
	for( int q = 4 ; q >=0 ; q--){
		printf("%d ",a[q]);
	}
}

C++: #include <iostream>
#include <string>
#include <vector>
#include <algorithm>
#include <cmath>
#include <cstdio>
#include <functional>
#include <numeric>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <utility>
#include <sstream>
#include <complex>

using namespace std;

#define FOR(i,a,b) for(long long i=(a);i<(b);i++)
#define REP(i,N) for(long long i=0;i<(N);i++)
#define ALL(s) (s).begin(),(s).end()
#define fi first
#define se second

#define PI acos(-1.0)
#define INF 1000000007

typedef long long ll;
typedef pair<ll, ll> P;
typedef pair<double, double> PD;
typedef pair<string, ll> PS;
typedef vector<ll> V;

ll a;
V vi;

int main(){
	REP(i, 5){
		cin >> a;
		vi.push_back(a);
	}
	sort(ALL(vi), greater<int>());
	REP(i, 5){
		cout << vi[i];
		if (i == 4)cout << endl;
		else cout << " ";
	}
}

C++: #include<iostream>
using namespace  std;
int main()
{
	int a[5];
	for (int i = 0; i < 5; i++)
		cin >> a[i];
	for (int i = 0; i < 4; i++)
		for (int j = i + 1,t; j < 5; j++)
			if (a[i] < a[j])
			{
				t = a[i];
				a[i] = a[j];
				a[j] = t;
			}
	for (int i = 0; i < 5; i++)
	{
		if (i != 0)cout << " ";
		cout << a[i];
	}
	cout << endl;
	return 0;
}

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

int main() {
	int n[5],tmp;
	scanf("%d %d %d %d %d",&n[0],&n[1],&n[2],&n[3],&n[4]);
	for (int i=0; i<4; i++)
	{
		for (int j=0; j<4-i; j++)
		{
			if (n[j]<n[j+1])
			{
				tmp = n[j];
				n[j] = n[j+1];
				n[j+1] = tmp;
			}
		}
	}
	cout << n[0] << " " << n[1] << " " << n[2] << " " << n[3] << " " << n[4] << endl;
	return 0;
}

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

int main(void)
{
	int d[5];

	for(int i = 0; i < 5; i++)
		cin >> d[i];
	sort(d,d+5);
	cout << d[4];
	for(int i = 3; i >= 0; i--)
		cout << ' ' << d[i];
	cout << endl;


	return 0;
}

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

int main()
{
    int Number[5];
    int Temp;

    while(cin >> Number[0] >> Number[1] >> Number[2] >> Number[3] >> Number[4])
    {
        for(int x = 0; x < 5; x++)
        {
            for(int z = 0; z < 5; z++)
            {
                if(Number[z] < Number[z+1])
                {
                    Temp = Number[z+1];
                    Number[z+1] = Number[z];
                    Number[z] = Temp;
                }
            }
        }

        for(int y = 0; y < 5; y++)
        {
            cout << Number[y] << " ";
        }


    }

}

C++: #include <stdio.h>
#include <algorithm>

using namespace std ;

int a[4] ;

int main ( )
{
	while ( scanf ( "%d" , &a[0] ) == 1 ) {
		for ( int i = 1 ; i < 5 ; i++ ) {
			scanf ( "%d" , &a[i] ) ;
		}
		sort ( a , a + 5 ) ;
		for ( int i = 4 ; i >= 0 ; i-- ) {
			if ( i != 4 ) putchar ( ' ' ) ;
			printf ( "%d" , a[i] ) ;
		}
		putchar ( '\n' ) ;
	}
	return 0 ;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
using namespace std;
int main()
{
    int          input;
    vector<int>  array;
    for (int i=0; i<5; ++i) {
        cin >> input;
        array.push_back(input);
    }
    sort(array.begin(), array.end(), greater<int>());
    for (unsigned int i=0; i<5; ++i) {
        cout << array[i];
        if (i!=array.size()-1) cout << ' ';
    }
}

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

using namespace std;

int main() {
  int a[5];
  scanf("%d %d %d %d %d", &a[0], &a[1], &a[2], &a[3], &a[4]);
  sort(a, a+5);
  printf("%d %d %d %d %d\n", a[4], a[3], a[2], a[1], a[0]);
}