Go: package main

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

var maxint = 10000
var scanner = bufio.NewScanner(os.Stdin)

func nextInt() (int, error) {
	scanner.Scan()
	return strconv.Atoi(scanner.Text())
}

func main() {
	scanner.Split(bufio.ScanWords)
	arr := make([]int, 10)
	for i := range arr {
		n, _ := nextInt()
		arr[i] = n
	}

	sort.Slice(arr, func(i, j int) bool {
		return arr[i] >= arr[j]
	})

	arrStr := fmt.Sprintf("%+v", arr[0:3])
	arrStr = arrStr[1:(len(arrStr) - 1)]
	arrStr = strings.Replace(arrStr, " ", "\n", -1)
	fmt.Println(arrStr)
}

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

const static int MAX = 10000;

int main() {
    int R[MAX]={0};
    int e;

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

    int cnt = 0;
    for (int j = MAX - 1; j >= 0 ; j--){

        if  (cnt >= 3) break;

        if (R[j] != 0){
            cout << R[j] << endl;
            cnt++;
        }
    }
    return 0;
}

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

void swap(int *b, int *c)
{
    int tmp;
    tmp = *b;
    *c = *b;
    *b = tmp;
}

int main(void){

	int a[11],max1,max2,max3;

	for (int i=1; i<11; i++){
		while (true){ 
		cout << "山の高さ" << i << "（整数）" ;			
		cin >> a[i];
		if ((cin.good() == 1) && (a[i] >= 0) && (a[i] <= 10000)) {
			break;
		}
		}	
	}

	max1 = a[1];

	for (int i=2; i<11; i++){
		if (max1 < a[i]){
			swap(max1,a[i]);
		}
	}
	max2 = a[2];

	for (int i=3; i<11; i++){
		if (max2 < a[i]){
			swap(max2,a[i]);
		}
	}
	max3 = a[3];

	for (int i=4; i<11; i++){
		if (max3 < a[i]){
			swap(max3,a[i]);
		}
	}


		cout << max1 << endl;
		cout << max2 << endl;
		cout << max3 << endl;
		

return 0;
	}

C++: #include <iostream> //??\????????¨
#include <vector> //???????????±?????¨
#include <algorithm> //???????????¨
using namespace std;

int main(){
	int n;
	vector<int> high; //int????????????high?????£?¨?(????????????????????§????´???°?????????)

	for(int i=0;i<10;i++){
		cin >> n; //??´??°?????\???????????????n???????????????
		high.push_back(n); //push_back:?????°?????????????????????????????????
	}

	sort(high.begin(),high.end()); //begin:?????????????´???????????????¬??????????????????end:?????????????´???????????????¬???????????????

	for(int i=9;i>=7;i--){
			cout << high.at(i) << endl; //at:?????°????????????????´??????????
	}
	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);
	
	cout << h[9] << endl << h[8] << endl << h[7] << endl;
	
	return 0;
	
}

C++: #include<iostream>
#include<vector>
#include<algorithm>
using namespace std;
int main(){
  vector<int> high(10);
  for(int i=0; i<10; i++) cin >>high[i];
  sort(high.begin(),high.end());
  for(int i=9; i>=7; i--) cout <<high[i]<<endl;
  return 0;
}

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

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

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

int main()
{
	int x[9], i;
	for (i=1; i<=10; i++)
	{
		cin >> x[i];
		sort(x,x+i);
	}
	
	cout << x[10] << endl;
	cout << x[9] << endl;
	cout << x[8] << endl;
}

C++: #include<stdio.h>

int main(){
	
	int a[3]={-1,-1,-1},i,b;
	
	for(i=0;i<10;i++){
		
		scanf("%d",&b);
		
		if(b>=a[0]){
			
			a[2]=a[1];
			a[1]=a[0];
			a[0]=b;
		}
		else if(b>=a[1]){
			
			a[2]=a[1];
			a[1]=b;
		}
		else if(b>=a[2]){
			
			a[2]=b;
		}
		
		//printf("%d\n%d\n%d\n\n",a[0],a[1],a[2]);
	}
	printf("%d\n%d\n%d\n",a[0],a[1],a[2]);
	
	return 0;
}

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

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

int main()
{
	int m[10];
	for (int i=0; i<10; ++i)
		cin >> m[i];
	sort(m, m+10);
	for (int i=9; i>6; --i)
		cout << m[i] << '\n';
	return 0;
}

C++: #include<bits//stdc++.h>
using namespace std;
int main(){
    vector<int> a(10);
    for(int i = 0; i< 10;i++) cin >> a[i];
    sort(a.rbegin(),a.rend());
    cout << a[0] << endl;
    cout << a[1] << endl;
    cout << a[2] << endl;
}

C++: #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=9;i>6;i--){
		cout<<a[i]<<endl;
	}
	return 0;
}

C++: #include <iostream>

using namespace std;

static const int ARRAY_NUM = 10;

class sort{
private:
	int tmp;
public:
	int* bable(int a[]);
};

int* sort::bable(int a[]){
	for(int i=0;i<ARRAY_NUM;++i){
		for(int j=ARRAY_NUM-1;j>i;--j){
			if(a[j]>a[j-1]){
				tmp    = a[j-1];
				a[j-1] = a[j];
				a[j]   = tmp;
			}
		}
	}
	return a;
}

int main(void){

	sort sort;
	int hgt_mt[10];
	int* hgt_max;

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

	hgt_max = sort.bable(hgt_mt);

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

	return 0;
}

C++: import java.util.List;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Scanner;

public class Main {
	public static void main(String[]args){
		ListOfTop3Hills();
	}
	
	public static void QQ(){
		for(int i=1;i<10;i++){
			for(int j=1;j<10;j++)System.out.println(i+"x"+j+"="+(i*j));
		}
	}
	
	public static void ListOfTop3Hills(){
		Scanner scan = new Scanner(System.in);
		List<Integer> list = new ArrayList<Integer>();
		
		for(int i=0;i<10;i++)list.add(scan.nextInt());
		Collections.sort(list);
		System.out.print(list.get(9)+"\n"+list.get(8)+"\n"+list.get(7));
	}
}

C++: #include <iostream>
#define N 10

using namespace std;

void swap(int& a, int& b){
	int tmp;
	if (a > b){
		tmp = a;
		a = b;
		b = tmp;
	}
}

void bubble(int mountain[N]){
	for (int i=0; i<(N-1); ++i){
		for (int j=i; j<(N-1); ++j){
			swap(mountain[j], mountain[j+1]);
		}
	}
}


int main(void){
	int mountain[N] = {0, };
	for (int i=0; i<N; ++i){
		cin >> mountain[i];
		if ((mountain[i] < 0) || (mountain[i] > 10000)){
			cout << "Range out!" << endl;
			return -1;
		}
	}
	bubble(mountain);
	//cout << "output!" << endl;
	for (int i=9; i>=7; --i){
		cout << mountain[i] << endl;
	}
	return 0;
}

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

C++: #include<iostream>?¬
   using namespace std;?¬
   ?¬
   const int MAX_N = 9;?¬
   int a[MAX_N];?¬
     ?¬
   int main(){?¬
   ?¬
       for(int i=0; i<=MAX_N; i++){?¬
           cin >> a[i];?¬
       }?¬
        ?¬
       sort(a,a+10);?¬
       cout << a[9] << endl << a[8] << endl << a[7] << endl;?¬
   ?¬
       return 0;?¬
   }?¬

C++: #include<iostream>
#include<vector>
#include<functional>
using namespace std;
int main(){
	vector<int> height(10);
	for(int i=0; i<10; i++){
		cin >>height[i];
	}
	sort(height.begin(),height.end(),greater<int>());
	cout <<height[0]<<endl<<height[1]<<endl<<height[2]<<endl;
	return 0;
}

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

int main() {
	int f=0,s=0,t=0,tmp;
	while(cin>>tmp, tmp!=EOF){
		if(f<tmp){f=tmp;}
		else if(s<tmp){s=tmp;}
		else if(t<tmp){t=tmp;}
	}
	cout<<f<<endl;
	cout<<s<<endl;
	cout<<t<<endl;
	return 0;
}

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

int main(){
  array<int,10> xs;
  for(int i=0;i<10;++i)scanf("%d",&xs[i]);
  sort(xs.begin(),xs.end(),greater<int>());
  for(int i=0;i<3;++i)printf("%d\n",xs[i]);
  return 0;
}