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++: //Vol0 0018
#include<stdio.h>
int main()
{
	int x[5],bak[5],c=-100001,t[5]={6},r=1,f=1;;
	for(int i=0;i<5;i++){
		scanf("%d",&x[i]);
	}
	for(int i=0;i<5;i++){
		for(int j=0;j<5;j++){
			r=1;
			if(f==1){
				for(int k=0;k<5;k++){
					if(t[k]==i){
						r=0;
						break;
					}
				}
				f=0;
			}
			if(c<x[j]&&r){
				c=x[j];
				t[i]=j;
			}
		}
		bak[i]=c;
	}
	for(int i=0;i<5;i++){
		printf("%d",bak[i]);
		if(i==4){
			printf("\n");
		}else{
			printf(" ");
		}
	}
	return 0;
}

C++: 
#include <iostream>

int main() {
	int array[5];

	for (auto& a : array)
	{
		std::cin >> a;
	}
	
	for (size_t i = 0; i < 4; i++)
	{
		int* pMax = &array[i];
		for (size_t j = i +1 ; j < 5; j++)
		{
			if (*pMax < array[j])
			{
				int tmp = *pMax;
				*pMax = array[j];
				array[j] = tmp;	
			}
		}
	}

	std::printf("%d %d %d %d %d\n", array[0], array[1], array[2], array[3], array[4]);

	return 0;
}

C++: #include <iostream>
using namespace std;
int main()
{
	int A[5] = {};
	cin >> A[0] >> A[1] >> A[2] >> A[3] >> A[4];
	for (int i = 1; i < 5; ++i){
		for (int j = i; j >= 1; --j){
			if (A[j] > A[j - 1]) swap(A[j], A[j - 1]);
			else break;
		}
	}
	cout << A[0] << " " << A[1] << " " << A[2] << " " << A[3] << " " << A[4] << "\n";
	return 0;
}

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

int main() {
	// your code goes here
	long long int a[5];
	for(int i=0;i<5;i++) cin >> a[i];
	for(int i=4;i>=0;i--) cout << a[i] << " ";
	
	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;

int main() {
	int a[5];
	while(cin >> a[0] >> a[1] >> a[2] >> a[3] >> a[4]){
		sort(a, a + 5, greater<int>());
		for(int i = 0; i < 5; ++i){
			if(i)
				cout << " ";
			cout << a[i];
		}
		cout << 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]);
	}

	return 0;
}

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

using namespace std;

int main(void)
{
	int a,b,c,d,e;
	while(cin>>a>>b>>c>>d>>e)
	{
		deque<int> nums;
		nums.push_back(a);
		nums.push_back(b);
		nums.push_back(c);
		nums.push_back(d);
		nums.push_back(e);
		sort( nums.begin(), nums.end(), greater<int>() );
		deque<int>::iterator it = nums.begin();
		while( it != nums.end() )
		{
			cout <<*it<<' ';
			++it;
		}
		puts("");
	}
	return 0;
}

C++: #include<stdio.h>
#define n 5

int main(void)
{
	int a[n],i,j,t;

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

	for( i = 1; i < n; ++i )
	{
		t = a[i];
		for( j = i; j > 0 && a[j-1] > t; --j )
		{
			a[j] = a[j-1];
		}
		a[j] = t;
	}
	for(i=n-1;i>-1;i--)
		printf("%d ",a[i]);
	printf("\n");
  return 0;
}

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

int main(){
	int a[5],tmp;
	for(int i=0; i<5 ; i++){
		cin >> a[i];
	}
	for(int j=0;j<4;j++){
		for(int k=j+1;k<5;k++){
			if(a[j]<a[k]){
				tmp = a[j];
				a[j] = a[k];
				a[k] = tmp;
			}
		}
	}

	for(int l =0; l<4 ; l++) {
		cout << a[l] << " ";
	}
	cout << a[4] << "\n";
}

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

using namespace std;

int main() {
  int n;
  int count = 0;
  priority_queue<int> que;
  while (cin >> n) {
    que.push(n);
    count++;
  }
  cout << que.top(); que.pop();
  for (int i = 0; i < count-1; i++) {
    cout << " " << que.top(); que.pop();
  }
  cout << endl;

  return 0;
}

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

  for(int i=0;i<5;i++)
    cout<<a[i]<<' ';
  cout<<endl;
  return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;

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

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

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

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

int main(){
	priority_queue<int> que;
	for(int i = 0;i < 5;i++){
		int a;
		cin >> a;
		que.push(a);
	}
	while(!que.empty()){
		cout << que.top() << " ";
		que.pop();
	}
	cout << endl;
	return 0;
}

C++: #include<stdio.h>
#define n 5

int main(void)
{
	int a[n],i,j,t;

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

	for( i = 1; i < n; ++i )
	{
		t = a[i];
		for( j = i; j > 0 && a[j-1] > t; --j )
		{
			a[j] = a[j-1];
		}
		a[j] = t;
	}
	printf("%d",a[n-1]);
	for(i=n-2;i>-1;i--)
		printf(" %d",a[i]);
	printf("\n");
  return 0;
}

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

#define FOR(var, start, end)    for(var = start; var < end; ++var)
#define WHILE(var, end)  while(var != end)
#define SHOW_ALL(a, b, c)    cout << a << endl; \
                                cout << b << endl; \
                                cout << c << endl;

using namespace std;


void BubbleSort(vector <int> &num)
{
      int i, j, flag = 1;    // set flag to 1 to start first pass
      int temp;             // holding variable
      int numLength = num.size( ); 
      for(i = 1; (i <= numLength) && flag; i++)
     {
          flag = 0;
          for (j=0; j < (numLength -1); j++)
         {
               if (num[j+1] > num[j])      // ascending order simply changes to <
              { 
                    temp = num[j];             // swap elements
                    num[j] = num[j+1];
                    num[j+1] = temp;
                    flag = 1;               // indicates that a swap occurred.
               }
          }
     }
     return;   //arrays are passed to functions by address; nothing is returned
}

int main()
{
    int input;
    vector<int> input_array;
    while(cin >> input){
        input_array.push_back(input);
    }
    BubbleSort(input_array);
    for(auto num:input_array){
        cout << num << " ";
    }
    
}

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

	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;

int main() {
    int T;
    string input;

    while(getline(cin, input)) {
        stringstream temp(input);

        int number;
        vector<int> vec;
        while(temp>>number) vec.push_back(number);

        sort( vec.rbegin(), vec.rend() );

        int size=vec.size();
        for(int i=0; i<size-1; i++) cout<<vec[i] <<" ";

        cout << vec[size-1] <<"\n";
    }
}

C++: #include<bits/stdc++.h>
using namespace std;

int main(){
    int a[5];
    for(int i=0;i<5;i++)cin>>a[i];
    sort(a,a+5);reverse(a,a+5);
    for(int i=0;i<5;i++)cout<<(i?" ":"")<<a[i];
    cout<<endl;
}