Go: package main

import "fmt"

func main() {
	var height int
	topHeights := [5]int{}

	for i := 0; i < 10; i++ {
		fmt.Scan(&height)

		for j := 0; j < 3; j++ {
			if topHeights[j] < height {
				topHeights[j+2] = topHeights[j+1]
				topHeights[j+1] = topHeights[j]
				topHeights[j] = height
				break
			}
		}
	}

	for i := 0; i < 3; i++ {
		fmt.Println(topHeights[i])
	}
}

C++: #include<iostream>
using namespace std;
int main() {
	int mountain[10];
	int a, b, c;

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

	a = mountain[0];
	b = mountain[1];
	c = mountain[2];

	for (int y = 3; y <= 9; y++) {
		if (a <= b) {
			if (a <= c) {
				if (a < mountain[y]) {
					a = mountain[y];
				}
			}
			else {
				if (c < mountain[y]) {
					c = mountain[y];
				}
			}
		}
		else if (b <= c)
		{
			if (b < mountain[y]) {
				b = mountain[y];
			}
		}
	}
	if (a <= b) {
		if (a <= c) {
			if (b <= c) {
				cout << c << "\n" << b << "\n" << a << "\n";
			}
			else {
				cout << b << "\n" << c << "\n" << a << "\n";
			}
		}
		else cout << b << "\n" << a << "\n" << c << "\n";
	}
	else if (a <= c) {
		cout << c << "\n" << a << "\n" << b << "\n";
	}
	else if (b <= c) {
		cout << a << "\n" << c << "\n" << b << "\n";
	}
	else cout << a << "\n" << b << "\n" << c << "\n";

	char a____;
	cin >> a____;

	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
int main()
{
    int arr[1000],n=10;
    for(int i=0; i<10; i++)
    {
        cin>>arr[i];
    }
    sort(arr,arr+n);
    for(int i=9; i>=7; i--)
    {
        cout<<arr[i]<<endl;
    }
}

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

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

int main()
{
	int a[s];
	for (int i = 0; i < s; i++)
	{
		cin>>a[i];
	}
	for (int i = 0; i < s; i++)
	{
		for (int j = i+1; j <= s; j++)
		{
			if(i==3)
				break;
			if(a[i]<a[j])
			{
				int temp=a[i];
				a[i]=a[j];
				a[j]=temp;
			}
		}
	}
	for (int i = 0; i < 3; i++)
	{
		cout<<a[i]<<endl;
	}
	
	return 0;
}

C++: #include <cmath>
#include <ctime>
#include <algorithm>
#include <iostream>
#include <map>
#include <numeric>
#include <set>
#include <sstream>
#include <string>
#include <vector>
#include <list>
#include <deque>
#include <stack>
#include <bitset>
#include <functional>
#include <numeric>
#include <utility>
#include <iomanip>
#include <cstdio>
#include <cctype>
#include <queue>
#include <complex>
#include <climits>

typedef long long ll;

using namespace std;

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

	sort(h, h+10, greater<int>());

	cout << h[0] << endl << h[1] << endl << h[2];
	while(1);
	

	return 0;
}

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

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

    //結果出力
    for(int i=0;i<3;i++)
         cout<<mountain[i]<<'\n';
    return 0;
}

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

using namespace std;

int main()
{
	vector<int> arr(10);
	
	for(int i = 0; i < 10; i++){
		cin >> arr[i];
	}
	
	sort(arr.begin(),arr.end());
	
	printf("%d\n%d\n%d\n",arr[10],arr[9],arr[8]);
	
	return 0;
}

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

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

C++: #include<iostream>

using namespace std;

int main(void){
  int a[10],b[3]={0}, c, d, i;
  for(i = 0;i<10;i++){
    cin >> a[i];
  }
  i=0;
  for(c=0;c<3;c++){
  for(i=0;i<10;i++){
    if(a[i] > b[c]){
      b[c] = a[i];
      d=i;
    }
  }
  a[d] = 0;
  }
  i=0;
  for(i=0;i<3;i++) cout << b[i] << endl;
}

C++: #include <iostream>                              
#include <algorithm>                             
                                                 
using namespace std;                             
                                                 
int main(int argc, char **argv) {                
    int mountain[10];                            
                                                 
    for (int i = 0; i < 10; i++) {               
        cin >> mountain[i];                      
    }                                            
                                                 
    sort(mountain, mountain + 10, greater<int>());
                                                 
    for (int j = 0; j < 3; j++) {                
        cout << mountain[j] << endl;             
    }                                            
                                                 
    return 0;                                    
}

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


int main() {
int a[10],i;	
for(int i=0; i<10; i++) cin>>a[i];
sort(a, a+10);
for(i=9; i>6; i--)
cout<<a[i]<<endl;
// your code goes here
	return 0;
}

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

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

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

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

int main()
{
    
    int i = 10,m[10];
    
    while(i>0){
        cin >> m[i];
        i--;
    }
    
    int max = m[0],index = 0;
    
    for(i = 0; i < 10 ; i++){
        if(max < m[i]){
            max = m[i];
            index = i;
        }
    }
    cout << m[index] << endl;;
    m[index] = 0;
    
    max = m[0];
    index = 0;
    
    for(i = 0; i < 10 ; i++){
        if(max < m[i]){
            max = m[i];
            index = i;
        }
    }
    cout << m[index] << endl;
    m[index] = 0;
    max = m[0];
    index = 0;
    
    for(i = 0; i < 10 ; i++){
        if(max < m[i]){
            max = m[i];
            index = i;
        }
    }
    cout << m[index] << endl;

    m[index] = 0;
    
    return 0;
}

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

int main()
{
    int h;
    int max1 = 0, max2 = 0, max3 = 0;
    while (cin >> h)
    {
	if (max1 <= h)
	{
	    max3 = max2; max2 = max1; max1 = h;
	}
	else if (max2 <= h)
	{
	    max3 = max2; max2 = h;
	}
	else if (max3 <= h)
	{
	    max3 = h;
	}
    }
    cout << max1 << endl;
    cout << max2 << endl;
    cout << max3 << endl;
    return 0;
}