Go: package main

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

func getsAsIntArray() (line []int) {
	scanner := bufio.NewScanner(os.Stdin)

	for scanner.Scan() {
		str := scanner.Text()
		if str == "" {
			break
		}
		data, err := strconv.Atoi(str)
		if err != nil {
			break
		}
		line = append(line, data)
	}

	return
}

func main() {

	lines := getsAsIntArray()
	sort.Sort(sort.Reverse(sort.IntSlice(lines)))
	for i, v := range lines {
		if i < 3 {
			fmt.Println(v)
		}
	}
}

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;
}

C++: #include <bits/stdc++.h>

using namespace std;

typedef long long ll;
typedef unsigned long long ull;
typedef long double ld;
typedef pair<ll, ll> P;

#define EACH(i,a) for (auto& i : a)
#define FOR(i,a,b) for (ll i=(a);i<(b);i++)
#define RFOR(i,a,b) for (ll i=(b)-1;i>=(a);i--)
#define REP(i,n) for (ll i=0;i<(n);i++)
#define RREP(i,n) for (ll i=(n)-1;i>=0;i--)
#define debug(x) cout<<#x<<": "<<x<<endl
#define pb push_back
#define ALL(a) (a).begin(),(a).end()

const ll linf = 1e18;
const int inf = 1e9;
const double eps = 1e-12;
const double pi = acos(-1);

template<typename T>
istream& operator>>(istream& is, vector<T>& vec) {
	EACH(x,vec) is >> x;
	return is;
}
template<typename T>
ostream& operator<<(ostream& os, vector<T>& vec) {
	REP(i,vec.size()) {
		if (i) os << " ";
		os << vec[i];
	}
	return os;
}
template<typename T>
ostream& operator<<(ostream& os, vector< vector<T> >& vec) {
	REP(i,vec.size()) {
		if (i) os << endl;
		os << vec[i];
	}
	return os;
}

int main() {
	std::ios::sync_with_stdio(false);
	std::cin.tie(0);
	vector<int> h(10); cin >> h;
	sort(ALL(h), greater<int>());
	REP(i, 3) cout << h[i] << endl;
}

C++: #include<iostream>

int main(){
	int a[10],b,Ichi=0,Ni=0,San=0,n,i;

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

	for(i=0;i<10;i++){
		if(a[i]>Ichi){
			b=Ichi;
			Ichi=a[i];
			a[i]=b;
		}
		if(a[i]>Ni){
			b=Ni;
			Ni=a[i];
			a[i]=b;
		}
		if(a[i]>San){
			b=San;
			San=a[i];
			a[i]=b;
		}
	}

	std::cout<<Ichi<<std::endl<<Ni<<std::endl<<San<<std::endl;


	return 0;
}

C++: #include<bits/stdc++.h>
#define ll long long 
#define ull unsigned long long 
#define ld long double
#define ui unsigned int 
using namespace std;
int main()
{
	int* arr = new int[10];
	for (int i = 0; i < 10; i++) {
		cin >> arr[i];
	}
	sort(arr, arr + 10,greater<int>());
	cout << arr[0] << endl << arr[1] << endl << arr[2] << endl;
}

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

int main(){
    int moun[10];
    int temp;
    for(int i=0;i<10;i++)
        cin >> moun[i];

    for(int i=0;i<9;i++){
        for(int j=1;j<10;j++){
            if(moun[i]<moun[j]){
               temp = moun[i];
               moun[i] = moun[j];
               moun[j] = temp;
            }
        }
    }

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

C++: #include<iostream>
using namespace std;
int main() {
	int a[10],min1=-1,min2=-1,min3=-1, i,j,k,l;
	for (i = 1; i <= 10; i++) {
		cin >> a[i];
	}
	for (j = 1; j <= 10; j++) {
		if (a[j] > min1) {
			min1 = a[j];
		}
	}
	for (k = 1; k <= 10; k++) {
		if (a[k] > min2 && a[k]!=min1) {
			min2 = a[k];
		}
	}
	for (l = 1; l <= 10; l++) {
		if (a[l] > min3&&a[l]!=min2&&a[l]!=min1) {
			min3 = a[l];
		}
	}
	cout << min3 << " " << min2 << " " << min1 << " " << endl;
	return 0;
}

C++: /*
 * http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0001
 */
#include <iostream>
#include <vector>
#define COUNT 10

using namespace	std;

int
main()
{
	vector<int> heights(COUNT);
	for (int i = 0; i < COUNT; i++) {
		cin >> heights[i];
		cin.ignore();
	}
	sort(heights.begin(), heights.end(), greater<int>());
	for (int i = 0; i < 3; i++)
	  cout << heights[i] << endl;
	return 0;
}

C++: #include<iostream>
#include<algorithm>
using namespace std;
int main(){
  int sum[10];
  int  i;
  for(i = 0; i < 10 ;i++)
  cin >> sum[i];
  sort(sum+1,sum+10);
  for(i = 9 ; i > 6;i--)
    cout << sum[i] << endl;
    return 0;
  }

C++: #include<iostream>
using namespace std;
int main(){
	int ar[10],r[3],t=10;
	for(int i=0;i<10;i++)
		cin>>ar[i];
	for(int i=0;i<10;i++)
		for(int j=0;j<9;j++)
		if(ar[i]>ar[j]){
			int t;
			t=ar[i];
			ar[i]=ar[j];
			ar[j]=t;
		}
	for(int i=0;i<3;i++)
		cout<<ar[i]<<endl;
	return 0;
}

C++: #include<stdio.h>

int main(void){

	int h[10]/*={1819,2003,876,2840,1723,
		           1673,3776,2848,1592,922}*/;
	
	int i,j,t;
	for(i=0;i<10;i++){
		printf("山の高さ(整数）>>%d",i+1);
		scanf("%d",&h[i]);
	}
	for(i=0;i<9;i++)
	{
		for(j=i;j<10;j++)
		{
			if(h[i]<h[j])
			{
			   t=h[i];
			   h[i]=h[j];
			   h[j]=t;
			}
		}
	}
	for(i=0;i<3;i++)
	{
		printf("%d\n",h[i]);
	}


	return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
	int i,moun,high[10000],j=0;
	for(i=0;i<10000;i++)
	{
		high[i] = 0;
	}
	for(i=0;i<10;i++)
	{
		cin >> moun;
		high[moun] = 1;
	}
	for(i=9999;i>=0;i--)
	{
		if(high[i] == 1)
		{
			cout << i << endl;
			j++;
		}
		if(j == 3)
		{
			break;
		}
	}
	return 0;
}