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 <cstdio>
#include <cstdlib>
#include <functional>
#include <algorithm>

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

using namespace std;

int main() {
 int i = 0;
 int height[SIZE];
 char buf[256];

 while(i < SIZE) {
  scanf("%s",buf);

  if(atoi(buf) != 0) {
   if(atoi(buf) <= MAX) {
    height[i] = atoi(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<algorithm>
using namespace std;
int main(){
	int n[10],i,j;
	for(i=0;i<10;i++){
	cin>>n[i];
	}
	sort(n,n+10);
	for(i=10;i>7;i--){
		cout<<n[i-1]<<endl;
	}
return 0;
}

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

using namespace std;

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

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

using namespace std;

int main(){
	int i;
	int t[10];
	for(i=0;i<10;i++) scanf("%d", t+i);

	sort(t, t+10);
	printf("%d\n%d\n%d\n", t[9], t[8], t[7]);
}

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

using namespace std;

int main (int argc, char * const argv[]) {
    // insert code here...
    int h;
	int yama[10];
	for(int i=0;i<10;i++){
		cin >> h;
		yama[i]=h;
	}
	sort(yama, yama+10);
	
	cout << yama[9] <<endl;
	cout << yama[8] <<endl;
	cout << yama[7] <<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.at(i) ;
    sort(h.begin(),h.end()) ;
    reverse(h.begin(),h.end()) ;
    for(int i=0;i<3;i++){
        cout << h.at(i) << endl ;
    }
}

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

#define REP(i, s, n) for(int i = s; i < n; ++i)
#define rep(i, n)		 REP(i, 0, n)
#define SORT(c)			 sort((c).begin(), (c).end())
#define IINF					INT_MAX
#define LLINF					LLONG_MAX
#define DEBUG					false

int main(){
    vector<int> mountain(10);
    rep(i,10){
        cin>>mountain[i];
    }
    sort(mountain.begin(),mountain.end());
    for(int i=9;i>=7;i--){
        cout<<mountain[i]<<endl;
    }       
}

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

int main()
{
	int h[10] = {}, i = 0, n[3] = {};
	while (cin >> h[i++]) {
		if (h[i] > h[n[0]]) {
			n[2] = n[1];
			n[1] = n[0];
			n[0] = i;
		}
		else if (h[i] > h[n[1]]) {
			n[2] = n[1];
			n[1] = i;
		}
		else if (h[i] > h[n[2]]) {
			n[2] = i;
		}
	}
	for (int j = 0; j < 3; j++) {
		cout << h[n[j]] << endl;
	}
    return 0;
}

C++: #include "bits/stdc++.h"
using namespace std;
#define repi(i,a,b) for(int i=(a), i##_len=(b); i<i##_len; ++i)
#define rep(i,n) repi(i,0,n)
#define repi_(i,a,b) for(int i=(a), i##_len=(b); i<=i##_len; ++i)
#define rep_(i,n) repi_(i,0,n)
#define all(x) (x).begin(),(x).end()
#define vsort(v) sort((v).begin(), (v).end())
#define gsort(v) tsort(v); reverse((v).begin(), (v).end())
#define vrev(v) reverse((v).begin(), (v).end())
#define siz(v) ((int)(v).size())
#define ers(v, n) (v).erase((v).begin() + n)
#define cnt(v, n) count(all(v), n)
#define vmin(v) *min_element(v.begin(), v.end())
#define vmax(v) *max_element(v.begin(), v.end())
#define el "\n"
#define co(x) cout<<(x)<<el
#define coc(c, a, b) if(c)co((a));else co((b))
#define cosp(x) cout<<(x)<<' '
#define YES(c) coc(c,"YES", "NO")
#define Yes(c) coc(c,"Yes", "No")
#define yes(c) coc(c,"yes", "no")
#define POSSIBLE(c) coc(c, "POSSIBLE", "IMPOSSIBLE")
#define Possible(c) coc(c, "Possible", "Impossible")
#define possible(c) coc(c, "possible", "impossible")
#define inf INT_MAX
#ifdef tqktmp_2
#define gc() getchar(); getchar()
#else
#define gc() 1
#endif
const unsigned int bf0 = (1 << 0);
const unsigned int bf1 = (1 << 1);
const unsigned int bf2 = (1 << 2);
const unsigned int bf3 = (1 << 3);
const unsigned int bf4 = (1 << 4);
const unsigned int bf5 = (1 << 5);
const unsigned int bf6 = (1 << 6);
const unsigned int bf7 = (1 << 7);

typedef long long lint;
typedef vector<int> ivec; typedef vector<string> svec;

lint dx[8] = { 0,1,1,1,0,-1,-1,-1 },
dy[8] = { 1,1,0,-1,-1,-1,0,1 };

template<class T>inline bool maxi(T &a, const T &b) { if (a<b) { a = b; return 1; } return 0; }
template<class T>inline bool mini(T &a, const T &b) { if (b<a) { a = b; return 1; } return 0; }




int main() {
	cin.tie(0);
	ios::sync_with_stdio(0);

	lint a[10];
	rep(i, 10)cin >> a[i];
	sort(a, a + 10);
	rep(i, 3)co(a[9 - i]);
	gc();
}

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

int main()
{
int a[10];
int b[10];
for(int i=0;i++;i<10)
{
cin>>a[i];
for(int j=0;j++;j<10)
{
if(a[i]>b[j])
{
for(int k=10-j;k--;k>0)
{
b[j+k]=b[j+k-1];
}
b[j]=a[i];
break;
}
}
}
for(int n=0;n++;n<3)
{
cout<<b[n];
}
}

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

int main() {
  int N ;
  vector<int>Mountain(N);
  for(int i = 0; i < N; i++){
    cin >> Mountain(i);
  }
  sort(Mountain.begin(), Mountain.endl());

  for(int j = 0; j < 3; j++){
    cout << Mountain(j) << endl;
  }
    }
  }
}

C++: #include <istream>
#include <fstream>
#define SIZE 10
#define TOPNUM 3
using namespace std;

int main(){
	ifstream ifs("data.txt");
	if( !ifs ) return 1;
	int height[SIZE],top[TOPNUM+1]={0};
	for( int i=0;i<SIZE;i++ ){
		ifs>>height[i];
		if( height[i]<0||10000<height[i] )
			return 1;
		for( int j=0;j<TOPNUM;j++ ){
			if( height[i]>top[j] ){
				for( int k=TOPNUM;k>j;k-- ){
					top[k]=top[k-1];
				}
				top[j]=height[i];
				break;
			}
		}
	}
	for( int i=0;i<TOPNUM;i++ ){
		cout<<top[i]<<endl;
	}
}

C++: #include <iostream>

using namespace std;

void reverse(int *array, int length) {
	int i;
	int j;
	for(i=0;i<length-1;i++){
		for(j=i+1;j<length;j++){
			if(array[i]<array[j]){
				int temp=array[i];
				array[i]=array[j];
				array[j]=temp;
			}
		}
	}
}

int main() {
	int mountain[10];
	for (int i = 0; i < 10; i++) {
		cin >> mountain[i];
	}
	reverse(mountain, 10);
	for (int i = 0; i < 3; i++) {
		cout << mountain[i] << endl;
	}
}

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

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

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

int first = 0, second = 0, third = 0;

//for sort
void sort(){
	int buf = third;
	if(third > first){
	//3rd > 1st ,1->2 2->3 3->1
		third = second;
		second = first;
		first = buf;
	}else if(third > second){
	//3rd > 2nd ,2->3 3->2
		third = second;
		second = buf;
	}
}

int main(){
int buf;

for(int i = 0; i < 10; i++){
	cin >> buf;
	if(buf > third){
		third = buf;
		sort();
	}
}

//show
cout << first << "\n";
cout << second << "\n";
cout << third << "\n";

return 0;
}

C++: #include<iostream>
using namespace std;
int main(void){
	int T,t3,t2,t1;
	for(int i=0;i<10;i++){
		cin>>T;
		if(T>=t1){
			t1=T;
			t2=t1;
			t3=t2;
		}
		else if(T>=t2){
			t2=T;
			t3=t2;
		}
		else if(T>=t3){
			t3=T;
		}
	}
	cout<<t1<<endl<<t2<<endl<<t3;
	return 0;
}

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

int main()
{
  int m[10];
  int max = 0;
  for (int i=0; i<10; i++)
  {
    cin >> m[10];
  }
  for(int i=0; i<3; i++)
  {
    for(int j=0; j<9; j++)
    {
      if ( m[i] < m[i+1] ) max = i+1;
    }
    cout << m[max] << endl;
    m[max] = -1;
  }
}

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

using namespace std;

const int N = 10;
int a[N];

int main() {
  for(int i = 0; i < N; i++) {
    scanf("%d", &a[i]);
  }
  sort(a, a+N);
  for(int i = 0; i < 3; i++) printf("%d/n", a[i]);
}