Go: package main

import (
	"fmt"
	"sort"
)

func main() {
	mt := make([]int, 10)

	for i := 0; i < 10; i++ {
		fmt.Scan(&mt[i])
	}

	sort.Ints(mt)
	fmt.Printf("%d\n%d\n%d\n", mt[9], mt[8], mt[7])

}

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

int main()
{
  vector<int> v(10);
  for (int i = 0; i < 10; i++) {
    cin >> v[i];
  }
  sort(v.begin(), v.end(), greater<int>());
  for (int i = 0; i < 3; i++) {
    cout << v[i] << endl;
  }
  return 0;
}

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

int a[10];

int main(){
	for(int i=0; i<10; i++)
		std::cin >> a[i];
	std::sort(a,a+10);
	for(int i=0; i<3; i++)
		std::cout << a[9-i] << std::endl;
	return 0;
}

C++: #include <iostream>
using name space std

int main(){
int hight[10];
int Num;
int naka;
int flag;

for(Num=0;Num!=10;Num++)
{
cin>>hight[Num];
};

for(Num=0;flag!=0;flag=0,Num=0)
{
if(hight[Num]<hight[(Num+1)])
{naka=hight[Num];
hight[Num]=hight[(Num+1)];
hight[(Num+1)]=naka;
flag++;&#160;};
};

cin<<hight[0]<<endl;
cin<<hight[1]<<endl;
cin<<hight[2]<<endl;
return 0;
}

C++: #include<iostream>
#include<queue>
#include<string>
#include<stack>
#include<cstdio>

using namespace std;

int main(void)
{
  int a[10]={};
  int i=0;
  int j=0;

  for(i=0;i<10;i++)
    cin>>a[i];

  sort(a,a+10);

  cout<<a[9]<<endl<<a[8]<<endl<<a[7]<<endl;

}

C++: #include <iostream>
#include <string>
#include <stringstream>
#include <vector>
#include <algorithm>
#include <map>
#include <cstdlib>
using namespace std;

#define REP(i,n) for(int i=0;i<n;++i)
#define rep(n) REP(i,n)

int main()
{
	int hills[10];
	rep(10) cin>>hills[i];

	sort( hills, hills+9, greater<int>() );

	rep(3) cout<<hills[i]<<endl;

	return 0;
}

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

int main(){
  int i1,i2,i3,buff;
  for(int x = 0; x < 10; x++){
    cin >> i3;
    if(i3 > i2){
      buff = i2;
      i2 = i3;
      i3 = buff;
    }
    if(i2 > i1){
      buff = i1;
      i1 = i2;
      i2 = buff;
    }
    
  }
  cout << i1 << endl << i2 << endl << i3 << endl;
  return 0;
}

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

//x[a]で定義される配列を降順に並び替える
void sort_array(int x[],int a){
	int i,j,tmp;
	for(i=0;i<a-1;i++){
		for(j = i+1;j < a ; j++){
			if(x[i] < x[j]){
				tmp = x[i];
				x[i] = x[j];
                x[j] = tmp;
			}
		}
	}
}	

int main(){
	int x[10];
	int i;
	for(i = 0; i< 10; i++)
	{
		cin >> x[i];
	}
	sort_array(x , 10);
	cout << x[0] << endl;
	cout << x[1] << endl;
	cout << x[2] << endl;
	return 0;
}

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

int main(){
	vector<int> h(10);
	for(int i=0;i<=10;i++){
		cin >> h[i];
	}

	sort(h.begin(),h.end());

	for(int i=8;i<11;i++){
		cout << h[i] << endl;
	}

	return 0;
}

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

int main(){

int i,j,h,temp;
int m[10];



//入力
for(i=0; i<10; i++){
   cin >> h;

   if(h >= 0 and h <= 10000){
       m[i]=h;
   }else{
   i--;
   }
}



//ソート
    for (i = 0; i < 9; i++) {
        for (j = 9; j > i; j--) {
            if (m[j - 1] > m[j]) {  
                temp = m[j];  
                m[j] = m[j - 1];
                m[j - 1] = temp;
            }
        }
    }
    
    
//出力
for (i = 9; i > 6; i--) {
   cout << m[i] << "\n";
}

    return 0;
}

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

int main()
{
    int A[10];
    for (int i = 0; i < 10; i++)
        cin >> A[i];
    int first = A[0], second = A[1], third = A[2];
    if (second < third)swap(second, third);
    if (first < second)swap(first, second);
    if (second < third)swap(second, third);
    for (int j = 0; j < 7; j++) {
        if (third < A[j + 3])third = A[j + 3];
        else if (second < A[j + 3]) {
            third = second;
            second = A[j + 3];
        }
        else if (first < A[j + 3]) {
            third = second;
            second = first;
            first = A[j + 3];
        }
    }
    cout << first << endl << second << endl << third << endl;
    return 0;
}

C++: #include<iostream>

using namespace std;
int main()
{
int mount[10];
for(int i=0;i<10;i++)
{
cin >> mount[i];
}
int max[3];
int count[2]={};
max[0] = mount[0];
max[1] = mount[0];
max[2] = mount[0];
for(int i=1;i<10;i++)
{
if(mount[i]>max[0])
{
max[0] = mount[i];
count[0]=i;
}
}
if(count[0]==0)
{
max[1]=mount[1];
}
for(int i=1;i<10;i++)
{
if(mount[i]>max[1]&&i!=count[0])
{
max[1] = mount[i];
count[1]=i;
}
}
if(count[0]==0)
{
max[2]=mount[1];
if(count[1]=1);
{
max[2]=mount[2];
}
}
for(int i=1;i<10;i++)
{
if(mount[i]>max[2]&&count[0]!=i&&count[1]!=i)
{
max[2] = mount[i];
}
}
cout << max[0] << endl;
cout << max[1] << endl;
cout << max[2] << endl;
return 0;
}

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

int main() {
  priority_queue<int> que;
  for (int i = 0; i < 10; i++) {
    int height;
    cin >> height;
    que.push(height);
  }
  cout << que.top() << endl; que.pop();
  cout << que.top() << endl; que.pop();
  cout << que.top() << endl; que.pop();
  return 0;
}

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

int main(){
    vector <int> v;
    int a;    
    for(int i-;i<10;i++){
        cin >> a;
        v.push_back(a);
    }

    sort(v.begin(),v.end());

    cout << v[0] << endl << v[1] << endl << v[2] << endl;

    return 0;

}

C++: #include <iostream>

using namespace std;

int main(void){
	int val[10];

	for(int i=0;i<10;i++)
		cin >> val[10];

	for(int i=0;i<9;i++)
		for(int j=0;j<9;j++)
			if(val[j]<val[j+1]){
				int tmp=val[j];
				val[j]=val[j+1];
				val[j+1]=tmp;
			}

	for(int i=0;i<3;i++)
		cout << val[i] << endl;

	return 0;
}

C++: #include <iostream>


void bubbleSort(int *array, int size) {
  size -= 1;
  int temp = 0;

  for (int i = 0; i < size; i ++)
    for (int j = 0; j < size; j ++)
      if (array[j] < array[j + 1]) {
        temp = array[j];
        array[j] = array[j + 1];
        array[j + 1] = temp;
      }
}

int main() {
  int heights[10];
  int size = 0;
  for (int i = 0; i < 10; i ++)
    std::cin >> heights[i];
  size = sizeof(heights) / sizeof(*heights);

  bubbleSort(heights, size);

  for (int i = 0; i < 3; i ++)
    std::cout << heights[i] << std::endl;

  return 0;
}

C++: #include<iostream>
using namespace std;
  
int main(){
    int i;
    int A[10];
    for(i = 0; i < 10; i++){
        cin >> A[i];
    }
    int a = -1, b = -1, c = -1;
    for(i = 0; i < 10; i++){
        if(a < A[i]){ a = A[i]; }
        else if(b < A[i]){ b = A[i]; }
        else if(c < A[i]){ c = A[i]; }
    }
    cout << a << endl;
    cout << b << endl;
    cout << c << endl;
    return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
  int n[10];
    for(int i=0;i<10;i++)
      cin>>n[i];
  sort(n,n+10);
  for(int i=9;i>=7;i--){
    cout<<n[i]<<endl;
  }
  return 0;
}

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

using namespace std;

int main() {
  vector<int> A(4);
  while(cin >> A[0]) {
    for(int i = 0; i < 3; i++) {
      if(A[i] >= A[i+1]) swap(A[i], A[i+1]);
      else break;
    }
  }
  cout << endl;
  for(int i = 3; i > 0; i--) {
    cout << A[i] << endl;
  }
  return 0;
}

C++: #include <iostream>

void sort(int *a);

int main()
{
    int i,high[10];
    for(i = 0;i < 10;++i){
        std::cin >> high[i];
    }
    sort(high[0]);
    std::cout << high[0];
    std::cout << high[1];
    std::cout << high[2];
}

void sort(int *a)
{
        int i,first = 0,secand = 0,third = 0;
        for(i = 0;i < 10;++i){
           if(first < *(a + i)){
               first = *(a + i);
           }else if(secand < *(a + i)){
               secand = *(a + i);
           }else if(third < *(a + i)){
               third = *(a + i);
           }
        }
        *a = first;
        *(a + 1) = secand;
        *(a + 2) = third;
}