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<iostream>
using namespace std;
int main(){
  int m;
  int m1=0,m2=0,m3=0;
  while(cin>>m){
    if(m1>m){
      m3 = m2;     
      m2 = m1;     
      m1 = m;
    }
    else if(m2>m){
      m3 = m2;   
      m2 = m;
    }
    else if(m3>m){
      m3 = m;
    }
  }
  cout << m1 << endl << m2 << endl << m3 <<endl;
  return 0;
}

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

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

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

int main()
{
	int a[10];
	int data_size = sizeof(a) / sizeof(a[0]) - 1;
	for (int i=0;i<=data_size;i++)
		cin >> a[i];
	sort(a,a+sizeof(a) / sizeof(a[0]));
	for (int j=0;j<=3 - 1;j++)
		cout << a[j] << ",";
}

C++: #include<iostream>

using namespace std;

int main(){
 int x,buf;
 int H[3];

 for(int i = 0; i < 3; i++){
  H[i] = 0;
 }
 
 for(int i = 0; i < 10; i++){
  cin >> x;
  
  if(x > H[2]){
  
   H[2] = x;
   
   for(int j = 2; j > 0; j--){
  
    if(H[j] > H[j-1]){
     buf = H[j];
     H[j] = H[j-1];
     H[j-1] = buf;
    }
   }
  }
 }
 
 for(int i = 0; i < 3; i++)
    cout << H[i] << endl;
 
  return 0;
}

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

int main(){
  int a[10];
  for(int i = 0; i < 10; i++)
    scanf("%d" &a[i]);
  for(int i = 0; i < 9; i++){
    for(int j = i + 1; i < 10; i++){
      if(a[i] > a[j])
        swap(a[i], a[j]);
    }
  }
  for(int i = 0; i < 3; i++){
    printf("%d\n", a[i]);
  }
}

C++: #include <iostream>

using namespace std;

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

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

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


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


	return 0;
}

C++: #include <stdio.h>

int main(){

	int a[10] = {}, i, g, n;
	for (i = 0; i < 10; i++){ scanf("%d", &a[i]); }
	for (n = 0; n < 9; n++){
		for (i = 0; i < 9; i++){
			if (a[i] > a[i + 1]){
				g = a[i];
				a[i] = a[i + 1];
				a[i + 1] = g;
			}
		}
	}
	for (i = 0; i < 3; i++){ printf("%d\n", a[i]); }
	return 0;
}

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

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

C++: #include<iostream>
using namespace std;
int main(){
    cin.tie(0);
    ios::sync_with_stdio(false);
    int yama,top1=0,top2=0,top3=0;
    for(int i=0;i<10;i++){
        cin >> yama;
        if(top1<yama){
            top3 = top2;
            top2 = top1;
            top1 = yama;
        }
        else if(top2<yama){
            top3 = top2;
            top2 = yama;
        }
        else if(top3<yama){
            top3 = yama;
        }
    }
    cout << top1 << "\n" << top2 << "\n" << top3 << "\n";
}

C++: import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.arrays;

class aoj001{
  public static void main(string[] a){
    BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    int[] arr = new int[10]; 
    for (int i = 0; i<10; i++)
      arr[i] = integer.parseint(br.readline());

    arrays.sort(arr);
    for (int i = 0; i < 3; i++)
      system.out.println(arr[i]);
  }
}

C++: #include <bits/stdc++.h>
#include <vector>
using namespace std;
int a[100];
int main(){
	for(int i = 1; i <= 10; i++){
		cin >> a[i];
	}
	sort(a+1, a+11);
	cout << a[10] << "\n" << a[9] << "\n" << a[8] << "\n";
	return 0;
}

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

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

C++: #include <bits/stdc++.h>
using namespace std;
// define
#define int long long
#define UNIQUE(v) v.erase(unique(all(v)), v.end());
#define ZIP(v) sort(all(v)),UNIQUE(v)
#define ADD(a, b) a = (a + b) % mod
#define SUB(a, b) a = (a+mod-b)%mod
#define MUL(a, b) a = (((a)%mod) * ((b)%mod)) % mod
#define repi(i,m,n) for(int i = m;i < n;i++)
#define drep(i,n,m) for(int i = n;i >= m;i--)
#define rep(i,n) repi(i,0,n)
#define rrep(i,n) repi(i,1,n+1)
#define chmin(x,y) x = min(x,y)
#define chmax(x,y) x = max(x,y)
#define all(v) v.begin(),v.end()
#define rall(v) v.rbegin(), v.rend()
#define dmp(x,y) make_pair(x,y)
#define dmt(x, y, z) make_tuple(x, y, z)
#define pb(x) push_back(x)
#define pf(x) push_front(x)
#define fi first
#define se second
// debug
template <typename T, typename U>
ostream &operator<<(ostream &os, const pair<T, U> &p){
  os << "(" << p.first << "," << p.second << ")";return os;
}
template <typename T, typename U, typename V>
ostream &operator<<(ostream &os, const tuple<T, U, V> &t){
  os << "(" << get<0>(t) << "," << get<1>(t) << "," << get<2>(t) << ")";
  return os;
}
template <typename T>
ostream &operator<<(ostream &os, const vector<T> &v){
  for (auto it = v.begin();it != v.end();++it){
    if(it != v.begin())os << " ";os << *it;
  }return os;
}
template <typename T, typename U>
ostream &operator<<(ostream &os, const map<T, U> &mp){
  for(auto x: mp)os << "(" << x.first << "," << x.second << ")" << endl;
  return os;
}
template<typename T, int SIZE>
int array_length(const T (&)[SIZE]){return SIZE;}
template<typename T, int N>
void PRINTF(const T (&a)[N], int s = N, int t = -1, bool f = true){
	if(t == -1){rep(i,s){if(i)cout << " ";cout << a[i];}}
	else repi(i,s,t){if(i!=s)cout << " ";cout << a[i];}
	if(f)cout << "\n";
}
template<typename T, int N1, int N2>
void PRINTF(const T (&a)[N1][N2], int h = N1, int w = N2){
	rep(i,h){rep(j,w){cout << a[i][j] << " \n"[j==w-1];}}
}
string substr(const string &str, int S1, int S2 = -1){
  if(S2 == -1)return str.substr(S1);
  return str.substr(S1, S2-S1);
}
// typedef
typedef complex<double> Point;
typedef pair<int, int> P;
typedef pair<int, P> PP;
typedef pair<P, int> Pi;
typedef tuple<int, int, int> TT;
typedef pair<int, TT> PT;
typedef vector<int> vi;
typedef deque<int> dq;
const int inf = 1e9+7;
const int INF = 1e18+7;
// int sum = accumulate(a, a+n, 0LL);
// int mx = max_element(a, a+n);
// int mn = min_element(a, a+n);
// int cnt = count(a, a+n, k);


int a[20], c[20], s[20];
int get_rand(int min_rand, int max_rand){
  return rand()%(max_rand-min_rand)+min_rand;
}

signed main(){
  srand((unsigned int)time(NULL));
  int n = 10;
  rep(i,n)s[i] = i;
  rep(i,n)cin >> a[i];
  while(true){
    rep(i,n){
      int tmp = get_rand(i, n);
      swap(s[i], s[tmp]);
    }
    rep(i,n)c[i] = a[s[i]];
    int f = 1;
    rep(i, n-1)if(c[i] < c[i+1])f = 0;
    if(f){
      rep(i,3)cout << a[s[i]] << endl;
      break;
    }
  }
  return 0;
}