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++: //#define _GRIBCXX_DEBUG
#include <algorithm>
#include <cctype>
#include <climits>
#include <cmath>
#include <complex>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <functional>
#include <iostream>
#include <iomanip>
#include <list>
#include <map>
#include <memory>
#include <numeric>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <utility>
#include <vector>
using namespace std;


// ?????¬???????????¬??????
#pragma region MACRO
#define P(x) cout << (x) << endl
#define p(x) cout << (x)
#define PED cout << "\n"
#define rep(i,n) for(int i=0; i<(int)n; ++i)
#define REP(i,x,n) for(int i=x; i<(int)n; ++i)
#define repi(i,n) for(int i=0; i<=(int)n; ++i)
#define REPI(i,x,n) for(int i=x; i<=(int)n; ++i)
#define ILP while(true)
#define FOR(i,c) for(__typeof((c).begin())!=(c).begin(); i!=(c).end(); ++i)
#define ALL(c) (c).begin(), (c).end()
#define mp make_pair
#pragma endregion

#pragma region TYPE_DEF
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<string, string> pss;
typedef pair<string, int> psi;
typedef pair<int, string> pis;
typedef vector<int> vi;
typedef vector<double> vd;
typedef vector<long> vl;
typedef vector<long long> vll;
typedef vector<string> vs;
#pragma endregion


// Effective std
#pragma region ESTD
template<typename C, typename T>
constexpr int count(C& c, T t) { return count(ALL(c), t); }
template<typename C, typename F>
constexpr int count_if(C& c, F f) { return count_if(ALL(c), f); }
template<typename C, typename T, typename U>
constexpr void replace(C& c, T t, U u) { replace(ALL(c), t, u); }
template<typename C, typename F, typename U>
constexpr void replace_if(C& c, F f, U u) { (ALL(c), f, u); }
template<typename C>
constexpr void sort(C& c) { sort(ALL(c)); }
template<typename C, typename Pred>
constexpr void sort(C& c, Pred p) { sort(ALL(c), p); }
template<typename C>
constexpr void reverse(C& c) { reverse(ALL(c)); }
#pragma endregion


// ?´???°
#pragma region PRIME
bool is_prime(unsigned n) {
  switch(n) {
    case 0:
    case 1: return false;
    case 2: return true;
  }
  if (n%2==0) return false;
  for (unsigned i=3; i*i<=n; i+=2)
    if (n%i==0) return false;
  return true;
}
#pragma endregion


// ??§??????/?°?????????????
#pragma region TRANSFORM
void mutal_tr(string &s) {
  for(int i=s.size(); i--;) {
    if(islower(s[i])) s[i] = toupper(s[i]);
    else if (isupper(s[i])) s[i] = tolower(s[i]);
  }
}
void to_upper(string &s) { for(int i=s.size(); i--;) s[i] = toupper(s[i]); }
void to_lower(string &s) { for(int i=s.size(); i--;) s[i] = tolower(s[i]); }
#pragma endregion


// ??????
#pragma region SET
template<class T>
set<T> intersection(const set<T>& sa, const set<T>& sb) {
  set<T> ret;
  for(T a : sa) if(sb.find(a) != sb.end()) ret.insert(a);
  return ret;
}
#pragma endregion

// Union Find
#pragma region UF
struct UnionFind {
  vector<int> data;
  UnionFind(int size) : data(size, -1) {}
  bool union_set(int x, int y) {
    x = root(x); y = root(y);
    if(x!=y) {
      if(data[y] < data[x]) swap(x, y);
      data[x] += data[y]; data[y] = x;
    }
    return x != y;
  }
  bool find_set(int x, int y) { return root(x) == root(y); }
  int root(int x) { return data[x] < 0 ? x : data[x] = root(data[x]); }
  int size(int x) { return -data[root(x)]; }
};
#pragma endregion


// ?????°
#pragma region CONST_VAL
#define PI (2*acos(0.0))
#define EPS (1e-9)
#define MOD (int)(1e9+7)
#pragma endregion

int main() {
    vi v;
    rep(i,10) {
        int n;
        cin >> n;
        v.push_back(n);
    }
    sort(v);
    P(v[9]);
    P(v[8]);
    P(v[7]);
  return 0;
}

C++: File Edit Options Buffers Tools C++ Help
#include<iostream>
using namespace std;
int main(){
  int x, buf, i, j;
  int top[3];
  for(i = 0; i < 3; i++)
    top[i] = 0;

  for(i = 0; i < 10; i++){
    cin >> x;
    if(x > top[2]){
      top[2] = x;
      j = 2;
      while(j > 0){
        if(top[j-1] <top[j]){
          top[j-1] = buf;
          top[j-1] = top[j];
          top[j] = buf;
          j--;
        }else{
          break;
        }
      }
    }
  }

  for(i = 0; i<3; i++)
    cout << top[i] << '\n';

  return 0;
}

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

int main()
{
	vector<int> data(10,0);
	
	for(int i=1;i<=10;i++) 
		cin >> data[i];
	
	sort(data.begin(),data.end(),greater<int>());
	
	for(int j=0;j<=2;j++)
		cout << data[j] << endl;
	
	return 0;
}

C++: #include<iostream>

using namespace std;

int main()
{
	int high[10];
	for(int ix = 0;ix != 10;++ix)
		cin >> high[ix];

	int index = 0;
	for(int jx = 0;jx != 3;++jx){
		for(int ix = 0;ix != 10;++ix)
			if(high[index] <= high[ix])
				index = ix;
		cout <<high[index]<<endl;
		high[index] = 0;
	}

	return 0;
}

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

using namespace std;

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

 return 0;
}

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

using namespace std;

int main(){

??????vector<int> data;

    for(int i=0;i<10;i++)
    {
       int input;
       cin>>input;
       data.push_back(input);
    }
    
    sort(data.begin(),data.end(),greater<int>());
    
    for(int i=0;i<3;i++)
    {
       cout<<data[i]<<endl;
    }

    return 0;
}

C++: 
#include<cstdio>
 
int main(){
    int i,j,t,data[10];
     
    for(i=0;i<10;i++)
    {
        scanf("%d",&data[i]);
    }
     
    for(i=0;i<9;i++)
    {
        for(j=0;j<9-i;j++)
        {
            if(data[j]<data[j+1])
            {
                t=data[j];
                data[j]=data[j+1];
                data[j+1]=t;
            }
        }
    }
    for(i=0;i<3;i++)
    {
        printf("%d\n",data[i]);
    }
 
    return 0;
}

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

int main(){
	int N[10];

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

	sort(&N[0], &N[9], greater<int>());

	cout << N[0] << endl;
	cout << N[1] << endl;
	cout << N[2] << endl;

	return 0;
}

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>
using namespace std;

#define MAX 10000

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

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

using namespace std;

int main(){

	int i,j,copy;
	int n[10];

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

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

	for (i = 0; i < 3; i++) 
		cout << n[i] << endl;
	
	return 0;
}