Go: package main

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

func main() {
        fp := os.Stdin
        scanner := bufio.NewScanner(fp)
        var lst [3]int

        for scanner.Scan() {
                num, _ := strconv.Atoi(scanner.Text())
                if lst[0] < num {
                        lst[2] = lst[1]
                        lst[1] = lst[0]
                        lst[0] = num
                } else if lst[1] < num {
                        lst[2] = lst[1]
                        lst[1] = num
                } else if lst[2] < num {
                        lst[2] = num
                }
        }

        for _, i := range lst {
                fmt.Printf("%d\n", i)
        }
}

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

#define SIZE 10
#define MAX 10000
#define TOP 3

using namespace std;

int main() {
 int i = 0;
 int height[SIZE];
 char buf[256];

 while(i < SIZE) {
  cin >> buf;

  if(atoi(buf) != 0) {
   if(atoi(buf) <= MAX) {
    height[i] = atoi(buf);
    i++;
   }
  }
 }

 sort(height, height + SIZE, greater<int>());

 for(i = 0;i < TOP;i++) {
  cout << height[i] << endl;
 }

 return 0;
}

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

using namespace std;

int main(void)
{
	multiset<int> s;
	int i1;
	int h;

	for(i1=0;i1<10;i1++){
		cin>>h;
		s.insert(h);
	}

	multiset<int>::reverse_iterator rit=s.rbegin();
	for(i1=0;i1<3;i1++){
		cout<<(*rit)<<endl;
		rit++;
	}

	return 0;
}

C++: #include<iostream>
#include<iomanip>
#include<algorithm>
#include<cmath>
#include<cstring>
#include<stack>
#include<cstdio>
#include<queue>
#define PI 3.1415927
using namespace std;
int main() {
	int h[11];
	for (int i = 0; i < 10; i++) {
		cin >> h[i];
	}
	sort(h, h + 10);
	for (int i = 9; i > 6; i--) {
		cout << h[i] << endl;
	}
}

C++: #include<iostream>
using namespace std;
int main(){
int h[10];
int i;
for(i=0;i<10;i++)cin>>h[i];
sort(h,h+10);
for(i=0;i<3;i++)cout<<h[i]<<endl;
return 0;
}

C++: #include<iostream> 
using namespace std;
void bubblesort(int A[]){
	for(int i=0;i<10;i++){
		for(int j=10-1;j>i;j--){
			if(A[j]>A[j-1]){
			int t=	A[j-1];
			A[j-1]=A[j];
			A[j]=t;
			}
		}
	}	
}
int main(){
	int A[10];
	for(int i=0;i<10;i++){
		cin>>A[i];
	}
	for(int i=0;i<3;i++)
	{
		bubblesort(A);
		if(i>0)cout<<endl;
		cout<<A[i];
	 } 
    return  0;
}

C++: #include<stdio.h>
void cal(){
int mark[10],h[10],i,r,high;
	for(i=0;i<10;i++){
		scanf("%d",h+i);
		mark[i]=0;
	}
	for(r=1;r<=3;r++){
		high=0;
		for(i=1;i<10;i++)if(h[i]>h[high]&&!mark[i])high=i;
		printf("%d\n",h[high]);
		mark[high]=1;
		}
}
int main(){
	cal();
	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>
#include<algorithm>

using namespace std;

int main() {
	int m[10];

	for (int i = 0; i < 10; i++)cin >> m[11];

	stable_sort(m, m + 10);

	for (int i = 9; i > 6; i--)cout << m[i] << endl;

	return 0;
}

C++: #include<iostream>

using namespace std;

int main()
{
	int high[10] = { };
	int first = 0, second = 0, third = 0;
	
	for(int i = 0; i < 10; i++){
		cin >> high[i];
		
		if(first < high[i]){
			second = first;
			first = high[i];
		}
		else if(second < high[i]){
			third = second;
			second = high[i];
		}
		else if(third < high[i])
			third = high[i];
	}
	
	cout << first << endl << second << endl << third << endl;
	
	
	return 0;
}

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

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

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

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

int main ()
{
	multiset <int> s;
	int i, num;
	for( i= 0; i < 10; i++)
	{
     cin >> num;
	 s.insert(num);
	}
	multiset <int>::iterator j ;
	j= s.end();
	for(i = 0; i < 3; i++)
	{
	  j--;
      cout << *j << endl;
	}
	return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
    int data[11];
    int temp;
    for(int a = 0;a<10;a++)
    {
        cin >> data[a];
        if(data[a]<0||data[a]>10000)return 0;
    }

    for(int x=0;x<10;x++)
    {
        for(int y=0;y<10;y++)
        {
            if(data[y]<data[y+1])
            {
                temp = data[y];
                data[y] = data[y+1];
                data[y+1] = temp;
            }
        }
    }
    cout << data[0] <<endl;
    cout << data[1] <<endl;
    cout << data[2] <<endl;
}

C++: #include<iostream>
#include<string>
using namespace std;
int main(){
	int a[10];
	for(int i=0;i<10;i++)
		cin>>a[i];
	for(int i=0;i<9;i++){
      for(int j=9;j>i;j--){
	    if(a[j]>a[j-1]){
	    int t=a[j];
	    a[j]=a[j-1];
	    a[j-1]=t;
	   }
      }
    }
	cout<<a[0]<<endl;
	cout<<a[1]<<endl;
	cout<<a[2]<<endl;
	return 0;
}

C++: 1819
2003
876
2840
1723
1673
3776
2848
1592
922

C++: #include<cstdio>
#include<iostream>
#include<algorithm>
#include<vector>
#include<queue>
#include<string>
#define REP(i,n) for(long long int (i)=0;(i)<(n);i++)


using namespace std;


int main(){
  priority_queue<int,vector<int>,less<int>>Q;
  int n;
  REP(i,10){
    cin >> n;
    Q.push(n);
  }
  REP(i,3){ cout << Q.top()<<endl;Q.pop();
  }
  return 0;
}

C++: #include <iostream>

using namespace std;

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

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

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

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

using namespace std;

int main(void) {
	vector<int> tall;
	for (int i = 0; i < 10; i++) {
		int x;
		cin >> x;
		tall.push_back(x);
	}
	sort(tall.begin(), tall.end(), greater<int>());
	for (int i = 0; i < 3; i++)
		cout << tall[i] << endl;
	return 0;
}

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

typedef long int lint;
typedef long long int llint;
typedef pair<int, int> pii;
typedef pair<int, string> pis;
typedef pair<long, long> pll;

#define EACH(t, c) for (auto&& t : c)
#define ALL(c) begin(c), end(c)
#define FOR(i, s, e) for (int i = (s); i < (int)(e); ++i)
#define REP(i, n) FOR(i, 0, n)
#define endl '\n'
#define fk first
#define sv second

const int dx[] = {1, 0, -1, 0, 1, 1, -1, -1}, dy[] = {0, 1, 0, -1, 1, -1, 1, -1};
const int MOD = (int)1e9 + 7;
const int INF = 999999999;

template<typename T>
void print(const std::vector<T>& v, char sep=' ') {
  for (int i = 0; i < (int)v.size(); i++) {
    if (i != 0) cout << sep;
    cout << v[i];
  }
  cout << endl;
}

int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  int a[10];

  REP(i, 10) {
    cin >> a[i];
  }
  sort(ALL(a));

  REP(i, 3) {
    cout << a[9 - i] << endl;
  }
}

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

using namespace std;

int main(){
	int a[10];
	for (int i = 0; i < 10; i++)
	{
		cin>>a[i];
	}
	sort(a,a+10);
	for (int i = 0; i < 3; i++)
	{
		printf("%d\n",a[9-i]);
	}
	return 0;
}