Go: package main

import (
	"bufio"
	"os"
	"strconv"
	"sort"
	"fmt"
)

var scanner = bufio.NewScanner(os.Stdin)

func nextInt() int {
	scanner.Scan()
	i, e := strconv.Atoi(scanner.Text())
	if e != nil {
		panic(e)
	}
	return i
}
func main() {
	heighs := make([]int, 10)
	for i := range heighs {
		heighs[i] = nextInt()
	}
	sort.Sort(sort.Reverse(sort.IntSlice(heighs)))
	for i := 0; i < 3; i++ {
		fmt.Println(heighs[i])
	}
}

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

int main() {

    vector<int> a(10);
    for(int i = 0;i < 10;i++) cin >> a[i];
    
    sort(a.begin(),a.end());
    
    cout << a[9] << "\n" << a[8] << "\n" << a[7] << "\n";
    
return 0;
}

C++: #include <cstdio>
#include <vector>
#include <algorithm>
#include <functional>

using namespace std;

int main(){
    vector<int> val(10);
    
    for(int i = 0; i < 10; ++i){
        scanf("%d", &val[i]);
    }
    
    sort(val.begin(), val.end(), greater<int>());
    
    for(int i = 0; i < 3; ++i){
        printf("%d\n", val[i]);
    }
    
    return 0;
}

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

using namespace std;

const int numOfMountain = 10;

int main(int argc, char** argv){
    int mountainBuf;
    vector<int> mountains;

    for(int i = 0; i <= numOfMountain; i++) {
        mountainBuf = atoi(argv[i]);
        mountains.push_back(mountainBuf);
    }

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

    auto out = mountains.end();
    for(int i = 0; i < 3; i++) {
        cout << *--out << endl;
    }

    return 0;
}

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

int des(int x, int y) {
  return x > y;
}

int main() {
  int a[10];
  for (int i=0; i<10; i++) {
    cin >> a[i];
  }
  //sort(a, a+10, [](const int& x, const int& y) {return x > y;});
  sort(a, a+10, des);
  for (int i=0; i<3; i++) {
    cout << a[i] << endl;
  }
}

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

vector<int>vec;
int main(){
    for(int i=0;i<10;i++){
        int m;
        cin>>m;
        vec.push_back(m);
    }
    sort(vec.begin(),vec.end());
    for(int i=1;i<4;i++){
        cout<<*(vec.end()-i)<<endl;
    }
}

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

int main()
	{
	int i=0;
	int num[10];
	for(;i<10;i++)
		cin>>num[i];
	int temp=0,temp1=0,j=0;
	for(;j<3;j++)
		{
		for(i=0;i<10;i++)
			{	temp1=temp;
		temp=temp<num[i]?num[i]:temp;
		num[i]=temp1;
		}
		cout<<temp<<endl;
		temp=0;temp1=0;
	}
	
	return 0;
}

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

int main(){
	int height[10] = {0};

	for(int i = 0; i < 10; i++){
		cin >> height[i];
	}
	
	int temp = 0;
	for(int i = 0; i < 3; i++){
		for(int j = 0; j < 10-i; j++){
			if(height[j] > height[j+1]){
				temp = height[j];
				height[j] = height[j+1];
				height[j+1] = temp;
			}
		}
	}
	
	cout << height[9] << endl;
	cout << height[8] << endl;
	cout << height[7] << endl;
	
	return 0;
}

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

#define LEN 10

int main() {

    int hills[LEN] = {0};
    for (int i = 0; i < LEN; ++i) {
        cin >> hills[i];
    }

    sort(hills, hills + LEN);

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

    return 0;
}

C++: #include<iostream>
using namespace std;
int main()
{
	int i, j, t, a[10];
	cout << "The height of mountain" << endl;
	for (i = 0; i < 10;i++)
		cin >> a[i];
	for (j = 0; j <9; j++)
	for (i = 0; i < 9 - j; i++)
	if (a[i] < a[i + 1])
	{
		t = a[i]; a[i] = a[i + 1]; a[i + 1] = t;
	}
	cout << "The height of the top three mountains";
	cout << "\n";
	cout << a[0];
	cout << "\n";
	cout << a[1];
	cout << "\n";
	cout << a[2];
	cout << "\n";
	cout << endl;
	return 0;
}

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

int main(){
	vector<int> height(10);

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

	sort(height.begin(), height.end(), greater<int>());
	
	for (int i = 0; i < 3; i++)
		cout << height[i] << endl;
}

C++: #include <iostream>
using namespace std;
int main(void){
   int n, n1, n2, n3;
   n1 = 0;
   n2 = 0;
   n3 = 0;
   for(int i = 0; i < 10; i++){
       cin >> n;
       if(n > n1){
           n3 = n2;
           n2 = n1;
           n1 = n;
       }
       else if(n > n2){
           n3 = n2;
           n2 = n;
       }
       else if(n > n3){
           n3 = n;
       } 
   }
   cout << n1 << endl << n2 << endl << n3 << endl;
}

C++: #include <cstdio>
#include <vector>
#include <algorithm>
#include <functional>

using namespace std;

int main()
{
	vector<int> a(10);
	for(int i=0;i<10;i++)
		scanf("%d",&a[i]);
	sort(a.begin(),a.end(),greater<int>());
	for(int i=0;i<3;i++)
		printf("%d\n",a[i]);
	
	return 0;
}

C++: #include<iostream>
using namespace std;
int main()
{
	int a,mountain[10],j,k;
	for(int i=0;i<10;i++){
		cin>>mountain[i];
	}
	for(j=0;j<10;j++){
		for(k=0;k<10-j;k++){
			if(mountain[k]<mountain[k+1]){
				a=mountain[k];
				mountain[k]=mountain[k+1];
				mountain[k+1]=a;
			}
		}
	}
	cout<<mountain[0]<<"\n"<<mountain[1]<<"\n"<<mountain[2]<<"\n";
	return 0;
}

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

int main(){
    int mountain[10];
    
    for(int i=0;i<10;i++)
        //scanf("%d",&mountain[i]);
	cin>>mountain[i];
    for(int i=0;i<10;i++){
        for(int j=9;j>i;j--){
	    if(mountain[j]>mountain[j-1]){
            int temp = 0;
			temp = mountain[j];
			mountain[j] = mountain[j-1];
			mountain[j-1] = temp;
	    }
	}
    }

    //結果出力
    for(int i=0;i<10;i++)
         cout<<mountain[i]<<'\n';
    return 0;
}

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



	for(int i=0;i<3;i++){
		cout<<takasa[i]<<endl;
	}





	return 0;
}

C++: #include<stdio.h>
#include<algorithm>
int main(){
    int a[10];
    for(int i=0;i<10;i++)scanf("%d",&a[i]);
    std::sort(a,a+10);
    printf("%d\n%d\n%d\n",a[9],a[8],a[7]);
}

C++: #include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
bool cmp(int x,int y)
{
	return x > y;

}
int main()
{
	int a[11], i = 0;
	for (i = 0; i < 10; i++)
	{
		cin >> a[i];
	}
	sort(a, a + 10,cmp);
	for ( i = 0; i < 3; i++)
	{
		printf("%d\n", a[i]);
	}
	
}

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

using namespace std;

vector<int> heights;
int input;

int main(){
 while(cin >> input) heights.push_back(input);
 sort(input.begin(), input.end());
 auto itr = input.end();
 cout << *itr << "\n" << *(itr-1) << "\n" << *(itr-2) << endl;

 return 0;
}

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

int main(){
	int height[10];
	int i , j;
	for(i=0 ; i<10 ; i++){
		cin >> height[i] ;
	}
	cout << endl;
	
	for(i=9 ; i>0 ; i--){
		for(j=0 ; j<i ; j++){
			if (height[j]>=height[j+1]){
				height[j]^=height[j+1];
				height[j+1]^=height[j];
				height[j]^=height[j+1];
			}
		}
	}
	for(i=9 ; i>6 ; i--){
		cout << height[i] << endl;
	}
	return 0;
}

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

int main()
{
  int a[11]={0};
  int i,j,maxa,maxb,maxc;
  

  for(i=0; i<10; i++){
    scanf("%d",&a[i]);
    //    maxa=max(maxa,a[i]);
  }

  for(i=0; i<10; i++){
    for(j=0; j<10; j++){
      if(a[i]>a[j]){
	swap(a[i],a[j]);
      }
    }
  }

  maxa=a[0];
  maxb=a[1];
  maxc=a[2];

  printf("%d\n%d\n%d\n",maxa,maxb,maxc);
  
  return 0;
}