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 <iostream>
#include <cstdio>
using namespace std;

void quicksort(int x[10],int first,int last){
    int pivot,j,temp,i;

     if(first<last){
         pivot=first;
         i=first;
         j=last;

         while(i<j){
             while(x[i]>=x[pivot]&&i<last)
                 i++;
             while(x[j]<x[pivot])
                 j--;
             if(i<j){
                 temp=x[i];
                  x[i]=x[j];
                  x[j]=temp;
             }
         }

         temp=x[pivot];
         x[pivot]=x[j];
         x[j]=temp;
         quicksort(x,first,j-1);
         quicksort(x,j+1,last);

    }
}
int main()
{
    int i;
    int a[15];
    for(i=0;i<10;i++)
        scanf("%d",&a[i]);
    quicksort(a,0,9);

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

    return 0;
}

C++: #include<iostream>

#include<set>

int main(){
        std::multiset<int> st;
        int h;
        for(int i=0;i<10;i++){
                std::cin >> h;
                st.insert(h);
        }
        std::multiset<int>::reverse_iterator itr = st.rbegin();
        for(int i=0;i<3;i++){
                std::cout << *itr << std::endl;
                *itr++;
        }
        return 0;
}

C++: #include <stdio.h>

int height[10];

void scan(){
  for(int i = 0; i < 10; i++){
    scanf("%d", &height[i]);
  }
}

void sorting(){
    for(int numb = 0; numb < 9; numb++){
        for(int num = 0; num < 9-numb; num++){
            if(height[num] < height[num+1]){
                int stock = height[num];
                height[num] = height[num+1];
                height[num+1] = stock;
            }
        }
    }
}

int main(){
  scan();
  sorting();
  for(int a = 0; a < 3; a++){
    printf("Height%d: %d\n", a, height[a]); 
  }
  return 0;
}

C++: #include <iostream>
//#include <fstream.h>
//#include <cstring>
using namespace std;

int main() {
  
  int n[10];
  int temp,i,j;

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

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

  //cout << "\n";
  cout << n[0] << "\n";
  cout << n[1] << "\n";
  cout << n[2] << "\n";

  return 0;
}

C++: #include <iostream>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <vector>
#include <algorithm>
#include <utility>
#include <queue>
int n;
using namespace std;
int main(){
	priority_queue <int > dp;

	while(cin>>n){
		dp.push(n);
	}
	for(int i=0;i<3;i++){
		int output=dp.top();
		dp.pop();
		cout<<output;
	}
	return 0;
}

C++: #include <vector>
#include <list>
#include <map>
#include <set>
#include <stack>
#include <queue>
#include <deque>
#include <algorithm>
#include <utility>
#include <functional>
#include <sstream>
#include <iostream>
#include <cstdio>
#include <cmath>
#include <cstdlib>
#include <cctype>
#include <string>
#include <cstring>
#include <ctime>
#include <climits>
#include <cassert>
using namespace std;
inline int toInt(string s) {int v; istringstream sin(s);sin>>v;return v;}
template<class T> inline string toString(T x) {ostringstream sout;sout<<x;return sout.str();}
typedef vector<int> vi;
typedef vector<vi> vvi;
typedef vector<string> vs;
typedef pair<int, int> pii;
typedef long long ll;
#define ALL(a) (a).begin(),(a).end()
#define RALL(a) (a).rbegin(),(a).rend()
#define EXIST(s,e) ((s).find(e)!=(s).end())
#define EXIST2(s,e) (find(ALL(s),(e))!=(s).end())
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n) FOR(i,0,n)
#define EACH(t,i,c) for(t::iterator i=(c).begin(); i!=(c).end(); ++i)
const double EPS = 1e-10;
const double PI  = acos(-1.0);


int main(){
	vi a(10);
	REP(i,10){
		cin>>a[i];
	}
	sort(RALL(a));
	cout<<a[0]<<endl;
	cout<<a[1]<<endl;
	cout<<a[2]<<endl;
}

C++: #include<stdio.h>
#include<iostream>
using namespace std;
int main(){
	int a[10];
	int b=0;
	for(int i=0;i<10;i++){
		cin >> a[i];
	}
	int mou1,mou2,mou3;
	mou1=a[0];
	for(int i=0;i<10;i++){
		
		if(mou1<a[i]){
			mou1=a[i];
			b=i;
		}
	}
	a[b]=0;
	mou2=a[0];
	for(int i=0;i<10;i++){
		
		if(mou2<a[i]){
			mou2=a[i];
			b=i;
				
		}
	}a[b]=0;
	mou3=a[0];
	for(int i=0;i<10;i++){
		
		if(mou3<a[i]){
			mou3=a[i];
			b=i;
				
		}
	}
	cout<<mou1<<"\n"<<mou2<<"\n"<<mou3<<"\n";

	return 0;

}

C++: 
#include<bits/stdc++.h>
#define rep(i,n) for(int i=0; i<n; i++)
using namespace std;
int main(){
  int h[10];
  rep(i,10){
    cin >> h[i];
  }
  sort(h,h+10);
  reverse(h,h+10);
  rep(i,3){
    cout << h[i] << endl;
  }
  return 0;
}

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

int main(){

	int hill[]={0,0,0,0,0,0,0,0,0,0};

	for(int j=0;j<=9;j++){
		scanf("%d",&hill[j]);
	}

	int key;

	//sort
	for(key=9;key>=0;key--){

		for(int i=0;i<=key;i++){
			if(hill[i]>hill[i+1]){
				swap(hill[i],hill[i+1]);
			}
		}

	}

	printf("%d%d%d",hill[9],hill[8],hill[7]);

	return 0;

}

C++: a = Array.new
10.times do
	n = gets.to_i
	a.push n
end
a.sort!
puts "#{a[9]} #{a[8]} #{a[7]}"

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

int main(void) {
  int a[10], i;
  for(i = 0; i < 10; ++i)scanf("%d", &a[i]);
  std::sort(a, a + 10);
  for(i = 9; i >6; --i) printf("%d\n", a[i]);
  return 0;
}

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

#define for_(i,a,b) for(int i=(a);i<(b);++i)

int main() {
	int h[10] = {0};
	for_(i,0,10) cin >> h[i];
	sort(h, h + 10, greater< int >());
	for_(i,0,3) cout << h[i] << endl;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <string>
#include <stack>
#include <queue>
#include <map>
#include <set>
#include <cstdio>
#include <cstring>
#include <cmath>
#include <climits>
#define LL long long
const double pi=acos(-1.0);
using namespace std;
const int maxm = 20;
const double eps = 1e-6;
int cmp(const void *a,const void *b)
{
    return *(int*)b-*(int*)a;
}
int main()
{
    int a[10];
   for(int i=0;i<10;i++)
    scanf("%d",&a[i]);
   qsort(a,10,sizeof(int),cmp);
   printf("%d\n%d\n%d\n",a[0],a[1],a[2]);
   return 0;
}

C++: #include<stdio.h>
int main(void){
    int d,m1=0,m2=0,m3=0,i;
    for(i=0;i<10;i++){
        scanf("%d",&d);
        if(d>m1){
            m3=m2;
            m2=m1;
            m1=d;
        }else if(d>m2){
            m3=m2;
            m2=d;
        }else if(d>m3){
            m3=d;
        }
    }
    printf("%d\n",m1);
    printf("%d\n",m2);
    printf("%d\n",m3);
    return 0;
}

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

int main() {
    vector<int> v;
    for(int i = 0; i < 10; i++) {
        int x;
        cin >> x;
        v.push_back(x);
    }
    sort(v.begin(), v.end());
    string str;
    for(int i = 9; i >6; i--) {
        str += to_string(v[i]);
        str += "\n";
    }
    str.pop_back();
    cout << str << endl;
}

C++: #include <bits/stdc++.h>
using namespace std;
int a[10];
int main() {
	for(int i = 0; i < 10; i++) scanf("%d", &a[i]);
	sort(a, a + 10, greater<int>());
	for(int i = 0; i < 3; i++) printf("%d\n", a[i]);
	return 0;
}