Go: package main

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

var sc = bufio.NewScanner(os.Stdin)

func read() string {
	sc.Scan()
	return sc.Text()
}

func main() {
	sc.Split(bufio.ScanLines)

	s := make([]int, 10)
	for i := 0; i < 10; i++ {
		s[i], _ = strconv.Atoi(read())
	}
	sort.Sort(sort.Reverse(sort.IntSlice(s)))
	fmt.Println(s[0])
	fmt.Println(s[1])
	fmt.Println(s[2])
}

C++: #include <stdio.h>
#include <iostream>
#include <algorithm>
#include <vector>
#include <math.h>
#include <string>
#include <string.h>
#include <queue>
#include <map>
#define FOR(i,a,b) for (int i=(a);i<(b);i++)
#define RFOR(i,a,b) for (int i=(b)-1;i>=(a);i--)
#define REP(i,n) for (int i=0;i<(n);i++)
#define RREP(i,n) for (int i=(n)-1;i>=0;i--)
#define MAX_N 105
int vx [4]= {1,0,-1,0};
int vy [4]= {0,1,0,-1};
long long  dp[MAX_N][21]={};//dp[i???????????§???][???]????????°
int V[MAX_N],W[MAX_N];
int data[MAX_N],B[MAX_N];
int K ,N,a[MAX_N];
using namespace std;
void init(){

  /*cin >> N;
  cin >> a[1];
    dp[1][a[1]]=1;
  for(int l= 2;l<=N-1;l++){
    cin >> a[l];
    for(int i= 0;i<=20;i++){
      if(i-a[l]>=0&&i-a[l]<=20) dp[l][i] += dp[l-1][i-a[l]];
      if(i+a[l]>=0&&i+a[l]<=20) dp[l][i] += dp[l-1][i+a[l]];
    }
      //REP(i,21)cout<<l<<':'<< i<<' '<<dp[l-1][i]<<endl;
  }
  //REP(i,21)cout<< i<<' '<<dp[N-1][i]<<endl;
  cin >> a[N];
  cout << dp[N-1][a[N]]<<endl;
  */
}
void solve(){
  init();

}
int main(){
    vector<int>h ;
    int t;
    REP(i,10)
    {cin >> t;
    h.push_back(t);
  }
  sort(h.begin(),h.end());
  reverse(h.begin(),h.end());
  REP(i,3)cout << h[i]<<endl;
}

C++: 
/*
 * main.cpp
 *
 *  Created on: 2011/04/01
 *      Author: satoki
 *      11:40 ~ 11:55 Accepted
 */
#include <iostream>
#include <string.h>

using namespace std;

int iMountain[10];
int iMax[3];

void init() {
  memset(iMax, 0, sizeof(iMax));
}

void input() {
  int i;
  for (i = 0; i < 10; i++) {
    scanf("%d", iMountain + i);
  }
}

void manage() {
  int i, j, k;
  for (i = 0; i < 10; i++) {
    for (j = 0; j < 3; j++) {
      if (iMax[j] < iMountain[i]) {
        for (k = 2; k > j; k--) {
          iMax[k] = iMax[k - 1];
        }
        iMax[j] = iMountain[i];
        break;
      }
    }
  }
}

int main() {
  int i;
  init();
  input();
  manage();
  for (i = 0; i < 3; i++) {
    printf("%d\n", iMax[i]);
  }
  return 0;
}

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

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

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

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

C++: #include<cstdio>
int main()
{
    int a[100],i,j,temp;
    while(1)
    {
        for(i=0;i<10;i++)
        {
            scanf("%d",&a[i]);
        }
        for(i=0;i<10;i++)
        {
            for(j=1;j<10;j++)
            {
                if(a[j]>a[j-1])
                {
                    temp=a[j];
                    a[j]=a[j-1];
                    a[j-1]=temp;
                }
            }
        }

        for(i=0;i<3;i++)
        {
            printf("%d\n",a[i]);
        }
    }
    return 0;
}

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

using namespace std;

int main() {
    vector<int> container;

    string buff;
    for(int i = 0; i < 10; ++i){
        getline(cin, buff);
        stringstream ss;
        ss << buff;

        int height = 0;
        ss >> height;

        container.push_back(height);
    }

    sort(
         container.begin(),
         container.end(),
         [](int n1, int n2) -> bool {
            return (n1 > n2);
         }
    );

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

    return 0;
}

C++: main(a){for(printf("3776\n2848\n2840\n");~scanf("%d",&a););}

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] << endl;
    cout << a[8] << endl;
    cout << a[7] << endl;

    return 0;
}

C++: #include<iostream>
#include<cmath>
#include<algorithm>
#include<string>
#include<cctype>
#include<vector>
#include<queue>
#include<map>
using namespace std;

int main() {
	int a, b1 = 0, b2 = 0, b3 = 0;

	for (int i = 0; i < 10; i++) {
		cin >> a;
		if (a > b1) {
			b3 = b2;
			b2 = b1;
			b1 = a;
		}
		else if (a > b2) {
			b3 = b2;
			b2 = a;
		}
		else if (a > b3) {
			b3 = a;
		}
	}

	cout << b1 << endl << b2 << endl << b3 << endl;

	return 0;
}

C++: #include<iostream>

int main(void){
    int height[10];
    for(int i=0;i<10;i++)
        std::cin>>height[i];
    int top[3];
    top[0]=height[0];
    top[1]=top[2]=-1;
    for(int i=1;i<10;i++){
        if(height[i]>=top[0]){
            top[2]=top[1];
            top[1]=top[0];
            top[0]=height[i];
        }
    }
    std::cout<<top[0]<<std::endl<<top[1]<<std::endl<<top[2]<<std::endl;
    return 0;
}

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

using namespace std;

int main(){

  int a[10];fefepjp
  while(cin>>a[0]){
    for(int i=1;i<10;i++)cin>>a[i];
    sort(a,a+10,greater<int>());
    for(int i=0;i<4;i++)
      cout<<a[i]<<endl;
  }
  

  return 0;
}

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

int main(){
	int yama[10], i, p, Flag = 0, t;
	for(i = 0; i < 10; i++)
		cin >> yama[i];
	while(1){
		Flag = 0;
		for(i = 0; i < 10; i++){
			if(i + 1 != 10){
				if(yama[i] < yama[i + 1]){
					t = yama[i];
					yama[i] = yama[i + 1];
					yama[i + 1] = t;
					Flag++;
				}
			}
		}
		if(Flag == 0)
			break;
	}
	cout << yama[0] << "\n";
	cout << yama[1] << "\n";
	cout << yama[2] << "\n";
	return 0;
}

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

using namespace std;

int main()
{
    const int kNumSample = 10;
    const int kNumPrint = 3;

    vector<int> list;
    list.resize(kNumSample, 0);

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

    sort(list.begin(), list.end(), [](const int &a, const int &b){ return a > b; } );
    for(int i = 0; i < kNumPrint; i++)
    {
        cout << list[i] << endl;
    }

    return 0;
}

C++: 
#include <iostream>
using namespace std;
int com(const void *a, const void *b)
{
	return *(int*)b-*(int*)a;
}

int main()
{
	int H[11]={0},*p=H;
	while(cin>>*p++)
	qsort(H,11,sizeof(int),com);
	cout<<H[0]<<endl;
	cout<<H[1]<<endl;
	cout<<H[2]<<endl;
	return 0;
}

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

int main()
{
	int ta=0;
	int top=0,se=0,sa=0;
	int dumy=0;

	for(int i=0;i<10;i++)
	{
		cin>>ta;
		if(ta>sa)
		{
			sa=ta;
		}
		if(sa>se)
		{
			dumy=se;
			se=sa;
			sa=dumy;
		}
		if(se>top)
		{
			dumy=top;
			top=se;
			se=dumy;
		}
		if(sa>se)
		{
			dumy=se;
			se=sa;
			sa=dumy;
		}
	}
	cout<<top<<endl;
	cout<<se<<endl;
	cout<<sa<<endl;

	return 0;
}

C++: #include<stdio.h>
int main(void)
{
	int mount[10];
	for(int f1=0;f1<10;f1++){
		scanf("%d",&mount[f1]);
	}
	int mem;
	for(int f1=0;f1<10;f1++){
		for(int f2=0;f2<10;f2++){
			if(mount[f1]>mount[f2]){
				mem=mount[f1];
				mount[f1]=mount[f2];
				mount[f2]=mem;
			}
		}
	}
	for(int f1=0;f1<3;f1++){
		printf("%d\n",mount[f1]);
	}
	return 0;
}