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>
#include<functional>

using namespace std;

int main(){
	typedef vector<int> vint;
	typedef vector<int>::iterator vintit;

	const int SUM_OF_DATA = 10;
	const int TOP = 3;
	vint hList(SUM_OF_DATA);
	vint result(TOP);
	
	for (vintit it = hList.begin(), end = hList.end(); it != end; ++it) cin >> *it;

	partial_sort_copy(hList.begin(), hList.end(), result.begin(), result.end(), greater<int>());
	for (vintit it = result.begin(), end = result.end(); it != end; ++it) cout << *it << endl;
	
	return 0;
}

C++: #include<stdio.h>
#include<algorithm>

using namespace std;

int main() {
	int m[10];

	for (int i = 0; i < 10; i++)scanf("%d", &m[i]);

	stable_sort(m, m + 10);
	
	for(int i=9;i>6;i--)printf("%d\n", m[9]);

	return 0;
}

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

int main()
{
  int high;
  int temp1,temp2;
  int first=0,second=0,third=0;
  
  for(int i=0;i<10;i++){
    cout<<"山の高さ"<<i+1<<":";
    cin>>high;
    if(high>first){
      temp1=first;
      first=high;
      temp2=second;
      second=temp1;
      third=temp2;
    } else if (first>=high && high>second){
      temp2=second;
      second=high;
      third=temp2;
    } else if (second>=high && high>third){
      third=high;
    }
  }

  cout<<"1番目に高い山の高さ:"<<first<<endl;
  cout<<"2番目に高い山の高さ:"<<second<<endl;
  cout<<"3番目に高い山の高さ:"<<third<<endl;
  
  return 0;
}

C++: #include<bits/stdc++.h>
#define ll long long int
#define FOR(i,a,b) for(ll i=(ll)(a);i<(ll)(b);i++)
#define REP(i,n) FOR(i,0,n)
#define REP1(i,n) FOR(i,1,n)
using namespace std;
 /*temp*/

int main(){
    int a[10];
    REP(i,10){
        cin >> a[i];
    }
    sort(a, a+10);
    cout << a[9] << '\n'
         << a[8] << '\n'
         << a[7] << '\n';
}

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

#define SIZE 10
#define MAX 10000
#define TOP 3

using namespace std;

int main() {
 int i = 0;
 int buf;
 int height[SIZE];
 
 while(i < SIZE) {
  scanf("%d", &buf);
  
  height[i] = buf;

  ++i;
 }

 sort(height, height + SIZE, greater<int>());

 for(i = 0; i < TOP; ++i) {
  printf("%d/n",height[i]);
 }

 return 0;
}

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

using namespace std;

int main() {
	vector<int> v;
	for(int i = 0; i < 10; i++) {
		int h;
		cin >> h;
		v.push_back(h);
	}

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

	for (int i = 1; i <= 3; i++) {
		cout << v.at(v.size() - i) << endl;
	}

	return 0;
}

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

int main(){
int a[10];
int b;
int c;
int d;
int e;
c=0;
d=0;
e=0;
b=0;
while(b<10){
cin >> a[b];
if(c<a[b]){e=d;
           d=c;
           c=a[b];}
else if(d<a[b]){e=d;
                d=a[b];}
else if(e<a[b]){e=a[b];}
b=b+1;
}          
cout << c <<endl;
cout << d <<endl;
cout << e;
    return 0;
}

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

int main(){

	int i = 0,j=0,k=0;
	int mountain[11] = {1819,2003,876,2840,1723,1673,3776,2848,1592,922};

	for(i=0;i<10;i++){
		for(j=i+1;j<10;j++){
	if(mountain[i] < mountain[j]){
		k = mountain[j];
		mountain[j] = mountain[i] ;
		mountain[i] = k ;
	}
	}
	}

	for(i=0;i<3;i++){
		cout << mountain[i] <<"\n" ;
	}
    return 0;
}

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

int main(){
    
    int i;
    int max1, max2, max3;
    std::array <int, 10> hill;
    
    max2 = 0;
    max3 = 0;

    for (i = 0; i < 10; ++i) {
        std::cin >> hill.at(i);
        
        if (i == 0) max1 = hill.at(0);
        
        if (max1 < hill.at(i)) { 
            max2 = max1;                    
            max1 = hill.at(i);
        } else if (max2 < hill.at(i)) {
            max3 = max2;
            max2 = hill.at(i);
        } else if (max3 < hill.at(i)) max3 = hill.at(i);
        else {}
    }
    
    std::cout << max1 << std::endl << max2 << std::endl << max3 << std::endl;
    
    return 0;
}

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

#define N 10
int main(){
	int height[N];
	
	for(int i=0;i<N;i++){
		cin >> height[i];
	}
	
	sort(height,height+N);
	
	for(int j=N-1;j>N-4;j--){
		cout << height[j] << endl;
	}
	
	return 0;
}

C++: #include <cstdio>
#include <cstdlib>
#include <cmath>
#include <iostream>
#include <sstream>
#include <vector>
#include <string>
#include <queue>
#include <set>
#include <map>
#include <utility>
#include <algorithm>
#include <functional>

using namespace std;

#define rep(i,n) for((i)=0;(i)<(int)(n);(i)++)
#define each(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)

bool rev(int a, int b){ return a > b; }

int main(){
  int i, in[10];

  rep(i,10) cin >> in[i];
  sort(in, in+10, rev);
  rep(i,3) cout << in[i] << endl;

  return 0;
}

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

int main(){
	std::vector<int> o;
	for(int i=1;i<=10;i++){
		int in=0;
		std::cin>>in;
		o.push_back(in);
	}
	std::sort(o.begin(),o.end());
	std::cout<<o[9]<<std::endl<<o[8]<<std::endl<<o[7]<<std::endl;
}

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

int main(){
  int t[10];
  for(int i = 0; i < 10; i++){
    cin >> t[i];
  }
  sort(t, t + 10, greater<int>());

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

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

int main() {
	int a,one=0,two=0,three=0;
	for (int i=0;i<10;i++){
		cin>>a;
		if (a>three) three=a;
		if (three>two) swap(two,three);
		if (two>one) swap(one,two);
	}
		cout<<one<<endl<<two<<endl<<three;
	return 0;
}

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

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

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

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

C++: #include<iostream>
#include<vector>
using namespace std;
int main(){
	int a=0;
	std::vector<int> vec(10);
	for(int i=0;i<10;i++){
		std::cin>>vec[i];
	}
	for(int i=0;i<9;i++){
		if(vec[i]<vec[i+1]){
			a=vec[i];
			vec[i]=vec[i+1];
			vec[i+1]=a;
			a=0;
		}
	}
	std::cout<<vec[0]<<std::endl<<vec[1]<<std::endl<<vec[2]<<std::endl;
	return 0;
}

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

int main(void){
	int mt[10];
	for(int i=0;i<10;i++)
		cin>>mt[i];
	int max_mt[3]={0,};
	for(int j=0;j<3;j++){
		for(int k=0;k<10;k++){
			max_mt[j]=max(max_mt[j],mt[k]);
		}
		cout<<max_mt[j]<<endl;
		for(int ll=0;ll<10;ll++)
			if(max_mt[j]==mt[ll])
				mt[ll]=0;
	}
	return 0;
}

C++: #include <iostream>

int main() {
  int heights[16] = { 0 };
  int temp_result = 0;
  int index = 12;

  for(int i = 0; i < 10; i++) {
    std::cin >> heights[i];
  }

  for(int j = 0; j < 3; j++) {
    heights[index] = 0;
    index = 0;
    temp_result = 0;
    for(int i = 0; i < 10 i++) {
      if(temp_result < heights[i]) {
        temp_result = heights[i];
        index = i;
      }
    }
    std::cout << temp_result << std::endl;
  }


  return 0;
}

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

int main(){
	int i,tmp;
	int tall[3] = {0};
	int num[10];

	for(i = 0 ; i < 10 ; i++){
		cin >> num[i];
		if(tall[0] <= num[i]){
			tmp = tall[2];
			tall[2] = tall[1];
			tall[1] = tall[0];
			tall[0] = num[i];
		}
	}
	for( i = 0; i < 3 ; i++)
		cout << tall[i] << endl;
    return 0;
}