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 <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 <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main(){
vector<int> height;
int a;
while(cin>>a){
height.push_back(a);
}
sort(height.begin(), height.end(), greater<int>());
for(int i = 0; i < 3; i++)
cout << height[i] << endl;
}

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

int main() {
    vector<int>mountain(10);
    for(int i = 0; i < 10; i++){
      cin >> mountain.at(i);
    }
    sort(mountain.begin(), mountain.end());
    reverse(mountain.begin(), mountain.end());

    for(int i = 0; i < 3; i++){
      cout << mountain.at(i) <<endl;
    }
}

C++: #include "bits/stdc++.h"
#include<unordered_map>
#include<unordered_set>
#pragma warning(disable:4996)
using namespace std;
using ld = long double;
template<class T>
using Table = vector<vector<T>>;


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

C++: //
//  main.cpp
//  kyougi
//
//  Created by 寺林 一旭 on 2018/08/27.
//  Copyright © 2018年 寺林 一旭. All rights reserved.
//

#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main() {
 
    int num;
    vector<int> list;
    while(cin)
    {
    cin >> num;
        list.push_back(num);
   
    }
    sort(list.begin(), list.end(), greater<int>());
    for(int i = 0 ; i< 3 ; i++)
    {
        cout<< list[i] <<endl;
    }
    
    
    return 0;
}

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

C++: #include<iostream>

using namespace std;

//??\?????????
void swap(int *a, int *b){
	int temp = *a;
	*a = *b;
	*b = temp;
}

int main(){
	int str,mt[10];
	int i;
	
	for(i=0;i<10;i++){
		do{
			cin >> str;
		}while(0>str||str>10000);
		mt[i]=str;
	}
	
	// ????????????
	int num = 1;
	while(num<=3){
		str = mt[num-1];
		for(i=num;i<=10;i++){
			if(str<mt[i]){
				str = mt[i];
				swap(mt[num-1],mt[i]);
			}
		}
		cout << mt[num-1] << "\n";
		num++;
	}
	
	return 0;
}

C++: #include <iostream>
using namespace std;
int main(){
	int high[11] , i , j ;
	for( i=1 ; i<=10 ; i++ ){
		cin >> high[i] ;
	}
	for( i=1 ; i<=10 ; i++ ){
		for( j=1 ; j<=10 ; j++ ){
			if( high[i] > high[j] )
				swap( high[i] , high[j] );
		}
	}
	for( i=1 ; i<=3 ; i++ )
		cout << high[i] << endl;
}

C++: #include<stdio.h>
  
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 <iostream>
using namespace std;

void swap(int* x, int* y){
	int tmp = *x;
	*x = *y;
	*y = tmp;
}

int main(){
	int input = 0, a = 0, b = 0, c = 0;
	for(int i = 0; i <= 10; i++){
		cin >> input;
		if(c < input){
			swap(&c, &input);
		}
		if(b < c){
			swap(&b, &c);
		}
		if(a < b){
			swap(&a, &b);
		}
		if(a < c){
			swap(&a, &c);
		}
	}
	cout << a << endl;
	cout << b << endl;
	cout << c << endl;
	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
using uint = unsigned int;
using lint = long long int;
using ulint = unsigned long long int;
template<class T = int> using V = vector<T>;
template<class T = int> using VV = V< V<T> >;
template<class T, class U> void assign(V<T>& v, int n, const U& a) { v.assign(n, a); }
template<class T, class... Args> void assign(V<T>& v, int n, const Args&... args) { v.resize(n); for (auto&& e : v) assign(e, args...); }


int main() {
  cin.tie(nullptr); ios_base::sync_with_stdio(false);
  string str;
  V<> a;
  while (getline(cin, str)) {
    a.push_back(stoi(str));
  }
  sort(rbegin(a), rend(a));
  for (int i = 0; i < 3; ++i) {
    cout << a[i] << '\n';
  }
}

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

using namespace std;

int main(void){
	vector<int> height ;
	string s ;
	while(cin >> s){
		height.push_back(atoi(s.c_str()));
		
	}
	sort(height.begin(),height.end(),greater<int>());
	
	for(int i=0;i<3;i++){
		cout <<height[i]<<endl ;
	}
	
	return 0 ;
}

C++: import sys
a = []
s = sys.stdin.readline()
while s :
	a.append(int(s))
	s = sys.stdin.readline()

a.sort()
a.reverse()
for i in range(3) :
	print(a[i]);

C++: #include <iostream>
#include <algorithm>
using namespace std;
    
int main(){
	int data,m[10];

	while(cin >> data)
	{
		for (int j=0;j<=9;j++){
			
			if (data<=10000 && data >= 0) 
			m[j]=data;
		}
	}

for (int j=0;j<=9;j++){
for (int i=0;i<=9;i++){

	if (m[i] <= m[i+1])
		std::swap(m[i],m[i+1]);

}
}
 
for (int i=0;i<=9;i++){
cout <<  m[i] <<'\n';
}

    return 0;
}

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

int num[10];
int main(int argc, const char * argv[])
{
    int i;
    while (scanf("%d",&num[0])!=EOF)
    {
        for (i=1; i<=9; ++i)
        {
            scanf("%d",&num[i]);
        }
        sort(num, num+10);
        printf("%d\n%d\n%d\n",num[9],num[8],num[7]);
    }
    return 0;
}

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

int main( int argc, char **argv ) {

  int h[10] = {0};
  int i;
  int j;
  int temp;
  
  for (i = 0; i < 10; ++i) {
    scanf("%d", &h[i]);
  }
  
  for (i = 0; i < 9; ++i) {
    for (j = i + 1; j < 10; ++j) {
      if (h[i] < h[j]) {
        temp = h[i];
        h[i] = h[j];
        h[j] = temp;
      }
    }
  }

  for (i = 0; i < 3; ++i) {
    printf("%d\n", h[i]);
  }
  
  return EXIT_SUCCESS;
}

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

int main(int argc, char *argv[]){
	int max[3]={0,0,0};
	int tmp;
    for (int i=0; i < 10; ++i){
		cin >> tmp;
		if(max[0]<tmp ){
			max[2]=max[1]; max[1]=max[0]; max[0]=tmp; 
		}
		else if(max[1]<tmp ){
			max[2]=max[1]; max[1]=tmp; 
		}
		else if(max[2]<tmp ){
			max[2]=tmp; 
		}
	}

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

    return 0;
}