Go: package main

import (
        "fmt"
        "sort"
)


func main() {
        var s []int
        var n int
        for i := 0; i < 5; i++ {
                fmt.Scanf("%d", &n)
                s = append(s, n)
        }
        sort.Ints(s)
        for i:= 1; i <= len(s); i++ {
                fmt.Printf("%d", s[len(s)-i])
                if i < len(s) {
                        fmt.Printf(" ")
                }
        }
        fmt.Printf("\n")
}

C++: #include <iostream>
#include <string>
#include <vector>
#include <cmath>
#include <algorithm>
#include <cstdlib>
#include <ctime>
#include <cstdio>
#include <functional>
#include <complex>

using namespace std;

const double PI=3.14159265;

int main()
{
	int v[5];

	srand((unsigned)time(NULL));

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

	do{
		for(int i=0;i<5;i++) swap(v[i],v[rand()%5]);

	}while(!( (v[0]>=v[1])&&(v[1]>=v[2])&&(v[2]>=v[3])&&(v[3]>=v[4]) ));

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

	return 0;
}

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

using namespace std;

int a[5];
int main() {
	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 << endl;
		else cout << " ";
	}

	return 0;

}

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

using namespace std;

int main()
{
    int input[5];

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

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

    cout << input[0] << " " << input[1] << " " << input[2] << " " << input[3];
    cout << " " << input[4] << endl;

    return 0;
}

C++: #include <iostream>
#include <algorithm>
using std::cin;
using std::cout;
using std::endl;
using std::sort;
using std::greater;

int main() {
	const int N = 5;
	int num[N];
	for (int i = 0; i < N; ++i) {
		cin >> num[i];
	}
	sort(num, num + N, greater<int>());
	for (int i = 0; i < N; ++i) {
		cout << num[i];
		if (i == N - 1) {
			cout << endl;
		} else {
			cout << ' ';
		}
	}
	return 0;
}

C++: #include <iostream>

using namespace std;

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

C++: #include <bits/stdc++.h>
using namespace std;
using uint = unsigned int;
using lint = long long int;
using ulint = unsigned long long int;
template<class T = int> using V = vector<T>;
template<class T = int> using VV = V< V<T> >;
template<class T, class U> void assign(V<T>& v, int n, const U& a) { v.assign(n, a); }
template<class T, class... Args> void assign(V<T>& v, int n, const Args&... args) { v.resize(n); for (auto&& e : v) assign(e, args...); }


int main() {
  cin.tie(nullptr); ios_base::sync_with_stdio(false);
  V<> a(5); for (int i = 0; i < 5; ++i) cin >> a[i];
  sort(rbegin(a), rend(a));
  for (int i = 0; i < 5; ++i) {
    cout << a[i] << (i != 4 ? ' ' : '\n');
  }
}

C++: #include<stdio.h>

int main(void)
{
	int a,b,c,d,e,x[5],t=0;
	scanf("%d %d %d %d %d",&a,&b,&c,&d,&e);

	for(t;t<5;t++)
	if(a>=b&&a>=c&&a>=d&&a>=e)
	{
		printf("a");
		x[t]=a;
		a=-1;
	}
	else if(b>=c&&b>=d&&b>=e)
	{
			printf("b");
		x[t]=b;
		b=-1;
	}
	else if(c>=d&&c>=e)
	{
			printf("c");
		x[t]=c;
		c=-1;
	}
	else if(d>=e)
	{
			printf("d");
		x[t]=d;
		d=-1;
	}
	else
	{
			printf("e");
		x[t]=e;
		e=-1;
	}

	for(t=0;t<5;t++)
	{
		printf("%d ",x[t]);
	}
	return 0;
}

C++: #include <iostream> 
#include <cstdio>
#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=0;i<5;i++)
		printf("%d%c",a[i],i==4?'\n':' ');
    return 0;
}

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

inline void swap(int *a,int *b){
  int *tmp;
  tmp = a;
  a = b;
  b = tmp;
}

int main()
{
  int i,j,max;
  int a[5];

  while(cin >> a[0] >> a[1] >> a[2] >> a[3] >> a[4]){
    for(i=0;i<4;i++){
      max = i;
      for(j=i+1;j<5;j++){
	if(a[max]<a[j])max = j;
      }
      swap(a[i],a[max]);
    }
    for(i=0;i<4;i++)cout << a[i] << " ";
    cout << a[4] << endl;
  }

  return 0;
}

C++: #define _USE_MATH_DEFINES
#include <iostream>
#include <queue>
#include <vector>
#include <math.h>
#include <algorithm>
#include <iomanip>
#include <string>
#include <stack>
using namespace std;

int main(){
	priority_queue<int> q;
	for (int i = 0; i < 5; ++i) {
		int a;
		cin >> a;
		q.push(a);
	}
	for (int i = 0; i < 5; ++i) {
		cout << q.top();
		if (i != 4) cout << ' ';
		q.pop();
	}
	return 0;
}

C++: #include <bits/stdc++.h>
#include <vector>
using namespace std;
int a[9], h;
int main(){
	for(int i = 1; i <= 5; i++){
		cin >> a[i];
	}
	for(int i = 1; i <= 4; i++){
		for(int u = 5; u > i; u--){
			if(a[u] > a[u-1]){
				h = a[u];
				a[u] = a[u-1];
				a[u-1] = h;
			}
		}
	}
	for(int i = 1; i <= 5; i++){
		if(i == 5)
			cout << a[i] << "\n";
		else
			cout << a[i] << " ";
	}
	return 0;
}

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

int main() {
	multiset<int, greater<int>> ms; int temp;
	for (int i = 0; i < 5; i++) { cin >> temp; ms.insert(temp); }
	for (auto itr = ms.begin(); itr != ms.end(); itr++) {
		cout << *itr << (itr != --ms.end() ? " " : "");
	}
	cout << endl;
	return 0;
}

C++: #include<stdio.h> 

int main(void) 
{
	
	int i,j,temp;
	int data[5];
	
		
	for(i=0;i<5;i++){
		scanf("%d",&data[i]);
			}

		for(i=0;i<4;i++){
			for(j=i+1;j<5;j++){
				if(data[i]<data[j]){
					temp=data[i];
					data[i]=data[j];
					data[j]=temp;
				}
			}
		}
		
		for(i=0;i<4;i++){
			printf("%d ",data[i]);
		}

		printf("%d\n",data[5-1]);

		return 0;
}

C++: /*****include*****/
#include <iostream>
#include <fstream>

/*****デバッグ定義*****/
//#define DEBUG
/*****マクロ定義*****/

/*****名前空間*****/
using namespace std;

/*****グローバル変数置き場*****/
int number[5];

/*****その他関数置き場*****/
void Q_sort(int left,int right){
	int threshold = (number[left] + number[right])/2;
	int i;
	int j;
	i = left;
	j = right;
	do{
		while(number[i] < threshold)	i++;
		while(number[j] > threshold)	j--;
		if(i <= j){
			int swap = number[i];
			number[i] = number[j];
			number[j] = swap;
			i++;
			j--;
		}
	}while(i <= j);
	if(j > left)	Q_sort(left,j);
	if(i < right)	Q_sort(i,right);
}
/*****main関数*****/
int main(){
	/*****ファイルオープン*****/
#ifdef DEBUG
	ofstream fout("output.txt");
	ifstream fin("input.txt");
	if(!fout || !fin){
		cout << "Can't open the file.\n";
		return;
	}
#endif
	/*****変数置き場*****/
	for(int i=0;i<5;i++)	cin >> number[i];
	Q_sort(0,4);
	for(int i=0;i<5;i++){
		cout << number[4-i];
		if(i==4)	cout << endl;
		else		cout << " ";
	}
	/*****処理部*****/

	/*****処理終了後*****/
#ifdef DEBUG
	fout.close();
	fin.close();
#endif
	return 0;
}

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

int main() {
	vector<int> vec(5);
	for (int i = 0; i < 5; i++) cin >> vec[i];
	sort(vec.begin(), vec.end());
	reverse(vec.begin(), vec.end());
	for (int i = 0; i < 5; i++) {
		if (i == 0) cout << vec[i] << flush;
		else cout << " " << vec[i] << flush;
	}
	cout << endl;
	return 0;
}

C++: #include<iostream>
#include<vector>
#include<algorithm>
using namespace std;
int main(){
  vector<int> a(5);
  for(int i=0; i<5; i++) cin >>a[i];
  sort(a.begin(), a.end());
  cout <<a[4]<<" "<<a[3]<<" "<<a[2]<<" "<<a[1]<<" "<<a[0]<<endl;
  return 0;
}