Go: package main

import (
	"fmt"
	"sort"
)

func main() {
	var a, b, c, d, e int
	fmt.Scan(&a, &b, &c, &d, &e)
	dataset := []int{a, b, c, d, e}

	sort.Sort(sort.Reverse(sort.IntSlice(dataset)))
	fmt.Printf("%d %d %d %d %d\n", dataset[0], dataset[1], dataset[2], dataset[3], dataset[4])
}

C++: #include<iostream>
using namespace std;
int main()
{
    int a[5],temp;
    for(int i=0;i<5;i++)
        {
            cin>>a[i];
        }

    for(int i =0;i<5;i++)
        {
            for(int j=0;j<5;j++)
                {
                    if(a[i]>a[j])
                      {
                            temp = a[i];
                            a[i] = a[j];
                            a[j] = temp;
                      }
                }
        }

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

                return 0;
}

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

int main(void){
	double a, b, c, d, e;
	cin >> a >> b >> c >> d >> e;
	vector<double> v;
	v.push_back(a);
	v.push_back(b);
	v.push_back(c);
	v.push_back(d);
	v.push_back(e);
	sort( v.begin(), v.end(), greater<double>() );
	cout << v[0] << ' ' << v[1] << ' ' << v[2] << ' ' << v[3] << ' ' << v[4] << endl;
	return 0;
}

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

int main(){
int a;
int b[5];
int c;
int d;
int e;
c=0;
while(c<5){
b[c]=0;
c=c+1;
}
c=0;
while(c<5){
cin >>a;
d=0;
while(1){if(a>=b[d]){e=3; if(e>=d){while(e>=d){b[e+1]=b[e]; e=e-1;}} b[d]=a; break;} d=d+1;     }
c=c+1;
}
c=0;
while(c<5){
cout << b[c];
if(c<4){cout <<" ";}
c=c+1;}


}

C++: #include<iostream>
#include<algorithm>
#include<vector>
#include<stack>
#include<queue>
#include<cstdio>
#include<climits>
#include<cmath>
#include<cstring>
#include<string>
#include<complex>
#include<cfloat>
#include<cassert>

#define f first
#define s second
#define mp make_pair

#define REP(i,n) for(int i=0; i<(int)(n); i++)
#define FOR(i,c) for(__typeof((c).begin()) i=(c).begin(); i!=(c).end(); i++)
#define ALL(c) (c).begin(), (c).end()
#define EPS (1e-10)
using namespace std;

typedef unsigned int uint;
typedef long long ll;
typedef complex<double> P;

#define PI (3.1415926535)
#define EPS (1e-10)

int main(){
  vector<int> v(5);
  REP(i,5) cin>>v[i];
  sort(v.rbegin(),v.rend());
  REP(i,5) cout<<v[i]<<(i==4?'\n':' ');
  return 0;
}

C++: #include<iostream>

using namespace std;

int main() {
	int num[5];
	cin >> num[0] >> num[1] >> num[2] >> num[3] >> num[4];
	for (int i = 0; i < 5; i++) {
		for (int j = 0; j < 5; j++) {
			if (num[i] >= num[j]) {
				int tmp;
				tmp = num[i];
				num[i] = num[j];
				num[j] = tmp;
			}
		}
	}
	for (int i = 0;i<5; i++) {

		if (i != 4) {
			cout << num[i]<<" ";
		}
		else {
			cout << num[i] << endl;
		}
	}
	
}

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

int main(){
   int num[5];
   int M1 = 0, M2 = 0, M3= 0 , M4= 0 , M5 = 0;
   int I1 = 0, I2 = 0, I3= 0 , I4= 0 , I5 = 0 ;
   cin >> num[0] >> num[1] >> num[2] >> num[3] >> num[4] ;

   for(int i=0 ; i < 5; i++){
      if(M1 < nim[i]) {
          M1 = num[i];
          I1 = i;
       }
    }

    for(int i=0 ; i < 5; i++){
        if(i == I1 ) continue;
        if(M2 < nim[i]) {
           M2 = num[i];
           I2 = i;
        }
     }

for(int i=0 ; i < 5; i++){
if(i == I1 || i == I2 ) continue;
if(M3 < nim[i]) {
M3 = num[i];
I3 = i;
}
}

for(int i=0 ; i < 5; i++){
if( i == I1 || i == I2 || i == I3 ) continue;
if(M4 < nim[i]) {
M4 = num[i];
I4 = i;
}
}

for(int i=0 ; i < 5; i++){
if( i == I1 || i == I2 || i == I3 || i == I4 ) continue;
if(M5 < nim[i]) {
M5 = num[i];
I5 = i;
}
}

cout << M1 << " " << M2 << " " << M3 << " " << M4 << " " << M5 << endl;

return 0 ;
}

C++: #include<iostream>
#include<algorithm>
#include <functional>
using namespace std;
int main(){
	int d[6]={};
	for(int i=0;i<5;i++){
		cin>>d[i];
	}
	sort(d,d+5,greater<int>());
	for(int i=0;i<5;i++){
		cout<<d[i]<<" ";
	}
	
	return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <stack>
#include <queue>
#include <map>
#include <cmath>
#include <string>
#include <sstream>
#include <iomanip>
#include <complex>
using namespace std;

#define ll long long
#define vvi vector< vector<int> >
#define All(X) X.begin(),X.end()
#define FOR(i,a,b) for(int i=(int)(a);i<(int)(b);i++)
#define REP(i,n) for(int i=0;i<(int)(n);i++)
#define pb push_back 
ll gcd(ll a,ll b){return b?gcd(b,a%b):a;}
ll lcm(ll a,ll b){return a/gcd(a,b)*b;}

int main(){
	int data[5];
	REP(i,5) cin >> data[i];
	sort(data,data+5,greater<int>());
	REP(i,4) cout << data[i] << " ";
	cout << data[4] << endl;
}

C++: #include<iostream>
int main()
{
	int n[5];
	for (int i = 0; i < 5; i++)
	{
		std::cin >> n[i];
	}
	for (int i = 0; i < 5; i++)
	{
		int max = -100001, max_index = 0;
		for (int j = i; j < 5; j++)
		{
			if (max < n[j])
			{
				max = n[j];
				max_index = j;
			}
		}
		std::swap(n[i], n[max_index]);
	}
	for (int i = 0; i < 5; i++)
	{
		std::cout << n[i] << ' ';
	}
	std::cout << '\b' << std::endl;
	return 0;
}

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];
		if(i!=0){
			cout<<" ";
		}
	}
	cout<<endl;
}

C++: #include<stdio.h>
#include<string>
#include<stdlib.h>
#include<math.h>
#include<iostream>
#include<vector>
#include<algorithm>
#include<numeric>
#include<string.h>
#include<map>
#include<queue>

using namespace std;

typedef pair<int,int> pii;

#define rep(i,j) for(int i=0;i<(j);i++)
#define reps(i,j,k) for(int i=j;i<=k;i++)
#define in(i,j,k) ((i)>=(j)&&(i)<=(k))


int main(){
	int n[5];
	rep(i,5)scanf("%d",n+i);
	sort(n,n+5);
	rep(i,5)printf("%d%c",n[4-i],i<4?' ':'\n');
	return 0;
}

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

int main(){
	int a[5];
	int p;
	int temp;
	int i,j;
	int min;
	int minin;
	cin >> a[0] >> a[1] >> a[2] >> a[3] >> a[4];
	for(i=0;i<5;i++){
		min = a[i];
		minin = i;
		for(j=i+1;j<5;j++){
			if(min > a[j]){
				min = a[j];
				minin = j;
			}
		}
		temp = a[i];
		a[i] = a[minin];
		a[minin] = temp;
	}
	cout << a[0];
	for(i=1;i<5;i++){
		cout << " " << a[i];
	}
	cout << endl;
	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
int main(void){
	int box[5];
	int i,j;
	
	for(i=0;i<5;i++)	cin>>box[i];
	for(i=0;i<4;i++){
		for(j=i+1;j<5;j++){
			if(box[i]<box[j])	swap(box[i],box[j]);
		}
	}
	for(i=0;i<5;i++){
		if(i)	cout<<" ";
		cout<<box[i];
	}
	cout<<endl;
	return 0;
}

C++: #include<iostream>

using namespace std;

int main(){
  int a[5],b[5];
  cin>>a[0]>>a[1]>>a[2]>>a[3]>>a[4];

  for(int i=0;i<5;i++){
    for(int j=i;j<5;j++){
      if(a[i]<a[j]){
	swap(a[i],a[j]);
      }
    }
  }
  for(int i=0;i<4;i++)
    cout<<a[i]<<' ';
  cout<<a[4]<<"\n";
}

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

using namespace std;

bool descend(int i, int j) { return (i < j); }

int main()
{
    int input[5];

    for (int i = 0; i < 5; i++)
        cin >> input[i];

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

    for (int i = 0; i < 5; i++)
        cout << input[i] << " ";
    cout << endl;

    return 0;
}

C++: import java.util.*;

public class Main {
	void run() {
		Scanner sc = new Scanner(System.in);
		
		int[] num = new int [5];
		for (int i=0;i<5;i++) {
			num[i] = sc.nextInt();
		}
		Arrays.sort(num);
		
		for (int i=num.length-1;i>=0;i--) {
			System.out.print(num[i]);
			if (i != 0)System.out.print(" ");
			else System.out.println();
		}
	}
	
	public static void main (String[] args) {
		new Main().run();
	}
}