Go: package main

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

var sc = bufio.NewScanner(os.Stdin)

func main() {
	heights := make([]int, 10)
	for i := 0; i < 10; i++ {
		sc.Scan()
		heights[i], _ = strconv.Atoi(sc.Text())
	}

	sort.Sort(sort.Reverse(sort.IntSlice(heights)))
	for i := 0; i < 3; i++ {
		fmt.Println(heights[i])
	}
}

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

int main(){
	int nyuryoku,high,low,middle,flag;
	
	for(int i=0;i<10;i++){
	cin>>nyuryoku;
	if(flag==0){
	high = nyuryoku;
	}else{
	if(nyuryoku>low){
		if(nyuryoku>middle){
			if(nyuryoku>high){
				high = nyuryoku;
			}else
				middle = nyuryoku
			}else
				low = nyuryoku;
		}
		}
	}
	cout<<high<<endl;
	cout<<middle<<endl;
	cout<<low<<endl;
return 0;
}

C++: #include <iostream>

using namespace std;

int main()
{
    int array [10];//={1819,2003,876,2840,1723,1673,3776,2848,1592,922};
    int tmp=0;
    for (int i=0;i<10;i++)
    {
        cout<<"height of mountain "<<i+1<<" ";
        cin>> array[i];
    }
    for (int i=9;i>=0;i--)
    {
        for (int j=0;j<i;j++)
        {
            if (array[i] > array[j] )
                {
                    tmp = array[i];
                    array[i] = array[j];
                    array[j] = tmp;
                }
        }
    }
    cout<<array[0]<<endl;
    cout<<array[1]<<endl;
    cout<<array[2]<<endl;
    return 0;
}

C++: #include <iostream>

int main(){
	int first=0,second=0,third=0,height;
	for(int i=0;i<10;++i){
		std::cin>>height;
		if(height>first){
			second=first;
			first=height;
		}
		else if(height>second){
			third=second;
			second=height;
		}
		else if(height>third){
			third=height;
		}
	}
	std::cout<<first<<'\n'<<second<<'\n'<<third<<'\n';
	return 0;
}

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

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

C++: #include<bits/stdc++.h>
using namespace std;
 
ostream &operator<<(ostream &os, __int128_t value) {
  if (ostream::sentry(os)) {
    __uint128_t tmp = value < 0 ? -value : value;
    char buffer[64];
    char *d = end(buffer);
    do {
      --d;
      *d = "0123456789"[tmp % 10];
      tmp /= 10;
    } while (tmp != 0);
    if (value < 0) {
      --d;
      *d = '-';
    }
    int len = end(buffer) - d;
    if (os.rdbuf()->sputn(d, len) != len) {
      os.setstate(ios_base::badbit);
    }
  }
  return os;
}
  
istream &operator>>(istream &is, __int128_t &value) {
  string in;
  is >> in;
  value = 0;
  for (const char &c : in) {
    if ('0' <= c && c <= '9') value = 10 * value + (c - '0');
  }
  if (in[0] == '-') value *= -1;
  return is;
}
  
__int128_t a[15];
  
int main(){
    for(int i=0;i<10;i++){
        cin>>a[i];
    }
    sort(a, a+10);
    cout<<a[9]<<endl
        <<a[8]<<endl
        <<a[7]<<endl;
}

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

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

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

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




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

	return 0;
}

C++: #include <iostream>
#include <set>
using namespace std;
int main() {
    multiset<int> s;
    for (int i = 0; i < 10; ++i) {
        int h;
        cin >> h;
        s.insert(h);
    }
    int i = 0;
    for (auto iter = s.crbegin(); i < 3; ++iter) {
        cout << *iter << endl;
        ++i;
    }
    return 0;
}

C++: #include<iostream>
using namespace std;
int main(){

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

    for(int i = 0; i < 3; i++){
        for(int j = i + 1; j < 10; j++){
            if(m[i] < m[j]){
                temp = m[i];
                m[i] = m[j];
                m[j] = temp;
            }
        }
    cout << m[i] << endl;
    }
}

C++: #include <iostream>
#include <cmath>
using namespace std;
int main(void){
    int mount[10]={}, i, max1=0, max2=0, max3=0;
     
    for(i=0; i<10; i++){
        cin >> mount[i];
        if(max3 < mount[i]){
            if(max2 < mount[i]){
                if(max1 < mount[i]){
                    max3 = max2;
                    max2 = max1;
                    max1 = mount[i];
                }
                else{
                    max3 = max2;
                    max2 = mount[i];
                }
            }
            else{
                max3 = mount[i];
            }
        }
    }
     
    cout << max1 << endl;
    cout << max2 << endl;
    cout << max3 << endl;
    return 0;
}

/*
　max1…１番高い山、max2…２番目に高い山、max3…３番目に高い山　とします。
　max1より高い山が現れたら、max1に設定し、max2、max3は順送りします。
　max1より低く、max2より高い山が現れたら、max2に設定し、max3は順送りします。
　max2より低く、max3より高い山が現れたら、max3に設定します。
*/

C++: #include <algorithm>
#include <iostream>
#include <list>
#include <map>
#include <math.h>
#include <stack>
#include <stdio.h>
#include <string>
#include <queue>
#include <vector>
using namespace std;

bool compare(int &a, int &b) {
	return a > b;
}

int main()
{
	int x;
	vector<int> A;
	while (cin >> x && x != EOF) {
		A.push_back(x);
	}

	sort(A.begin(), A.end(), compare);

	cout << A[0] << endl;
	cout << A[1] << endl;
	cout << A[2] << endl;
}

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

using namespace std;

int main(void)
{
	array<int, 10> input;

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

	sort(begin(input), end(input));

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


	return 0;
}

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

int main(){
	int mountain[10];
	
	for(int i=0; i<=9; i++){
		cin >> mountain[i];
	}
	
	sort(mountain,mountain+10);
	
	cout << mountain[9] << endl;
	cout << mountain[8] << endl;
	cout << mountain[7] << endl;	
	
	return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <vector>
using namespace std;
int main(){
  vector<int> heights(10);
  for (int i = 0; i < 10; i++) {
    cin >> heights[i];
  }

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

  return 0;
}

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