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 "stdio.h"

int main(){
  int height[10];
  for(int i = 0; i < 10; i++){
    scanf(" %d", &height[i]);
  }
  for(int numb = 0; numb < 9; numb++){
        for(int num = 0; num < 9-numb; num++){
            if(height[num] < height[num+1]){
                int stock = height[num];
                height[num] = height[num+1];
                height[num+1] = stock;
            }
        }
    }
  for(int a = 0; a < 3; a++){
    printf("%d\n", height[a]); 
  }
  return 0;
}

C++: #include <stdio.h>
#include <vector>
#include <algorithm>

int main(){
	//printf("Hello World!\n");
	std::vector<int> v;
	int x = -1;
	for(int i=0; i<10; i++){
		scanf("%d",&x);
		v.push_back(x);
	}
	std::sort(v.begin(),v.end());
	std::reverse(v.begin(),v.end());
	std::vector<int>::iterator begin = v.begin(); 
	for(int i =0; i<3; i++){
		int h = *begin;
		begin++;
		printf("%d\n",h);
	}

	
	return 0;
}

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

int main()
{
    vector<int> height;
    int buff;
    for(int i=0; i< 10; i++)
    {
        std::cin >> buff;
        height.push_back(buff);
    }
    sort(height.begin(), height.end());
    cout << height[height.size() - 1] << endl;
    cout << height[height.size() - 2] << endl;
    cout << height[height.size() - 3] << endl;
    
    return 0;
}

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

int main(){
	bool completed,flag;
	int result[3],buf,temp[10];
	for(int i = 0; i < 10; i++){
		cin >> temp[i];
	}
	for(int l = 0; l < 3; l++){
		while(1){
			for(int j = l; j < 9; j++){
				if(temp[j] < temp[j+1]){
					buf = temp[j+1];
					temp[j+1] = temp[j];
					temp[j] = buf;
				}
			}
			flag = false;
			for(int k = 0; k < 9; k++){
				if(temp[0] < temp[k]) flag = true;
			}
			if(flag != true){
				result[l] = temp[l];
				break;
			}
		}
	}
	cout << result[0] << endl;
	cout << result[1] << endl;
	cout << result[2] << endl;
	return 0;
}

C++: #include<bits/stdc++.h>
using namespace std;
 
signed main(){
  int a[10]{};
  for(int b=0;b<10;b++){
      scanf("%d",&a[b]);
      }
      sort(a,a+10);
      printf("%d\n%d\n%d\n",a[9],a[8],a[7]);
}

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

using namespace std;

int main()
{
	multiset<int, greater<int> > heights;
	int height;
	
	for (int i=0; i<10; i++)
	{
		cin >> height;
		heights.insert(height);
	}
	
	multiset<int>::iterator it = heights.begin();
	//while( it != heights.end() )
	for (int i=0; i<3; i++)
	{
		cout << *it << endl;
		++it;
	}
	
	
}

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

int main()
{
  int h1, h2, h3, n;
  h1 = h2 = h3 = 0;
  for(int i = 0; i < 10; i++){
    cin >> n;
    h1 = (i == 0) ? n : h1;
    if(n > h1){
      h3 = h2;
      h2 = h1;
      h1 = n;
    }else{
      if(n > h2){
	h3 = h2;
	h2 = n;
      }else{
	if(n > h3){
	  h3 = n;
	}
      }
    }
  }
  cout << h1 << endl << h2 << endl << h3 << endl;
}

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

int main(){
    
    int i;
    int max1, max2, max3;
    std::array <int, 10> hill;
    
    max2 = 0;
    max3 = 0;

    for (i = 0; i < 10; ++i) {
        std::cin >> hill.at(i);
        
        if (i == 0) max1 = hill.at(0);
        
        if (max1 < hill.at(i)) { 
            max2 = max1;                    
            max1 = hill.at(i);
        } else if (max2 < hill.at(i)) {
            max3 = max2;
            max2 = hill.at(i);
        } else if (max3 < hill.at(i)) max3 = hill.at(i);
        else {}
    }
    
    std::cout << max1 << std::endl << max2 << std::endl << max3 << std::endl;
    
    return 0;
}

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

using namespace std;

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

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

int main(void){
	int mountain[N];
	for (int i=0; i<N; ++i){
		int tmp;
		do{
			cin >> tmp;
		}while ((tmp<0) || (10000 < tmp));
		mountain[i] = tmp;
	}
	bubble_sort(mountain);
	//cout << "output" << endl;
	for (int i=0; i<3; ++i){
		cout << mountain[i] << endl;
	}
	return 0;
}

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

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

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

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

int main()
{
    int x[10];
    for (unsigned int i = 0; i < (sizeof(x) / sizeof(int)); i++)
        cin >> x[i];
    int first = 0;
    for (unsigned int i = 0; i < (sizeof(x) / sizeof(int)); i++)
        if (x[i] > first)
            first = x[i];
    int second = 0;
    for (unsigned int i = 0; i < (sizeof(x) / sizeof(int)); i++)
        if (x[i] > second && first > x[i])
            second = x[i];
    int third = 0;
    for (unsigned int i = 0; i < (sizeof(x) / sizeof(int)); i++)
        if (x[i] > third && second > x[i])
            third = x[i];
    cout << first << endl;
    cout << second << endl;
    cout << third << endl;
}

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]&&second>height[i])
			third=height[i];
	cout<<first<<endl<<second<<endl<<third<<endl;
	return 0;
}

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

int main(){
	const int N=10;
	int date[N];
	int tmp;

	for(int i=0;i<N;i++) cin>>data[i];
	for(int i=1;i<=3;i++){
		for(int j=0;j<N-i;j++){
			if(data[j]>data[j+1]){
				tmp=data[j];
				data[j]=data[j+1];
				data[j+1]=tmp;
			}
		}
	}
	cout<<data[N-1]<<endl<<data[N-2]<<endl<<data[N-3]<<endl;
}

C++: #include<stdio.h>
int main(void){
  int i,x,y,z,s,a;
    scanf("%d",&x);
    scanf("%d",&y);
    if(x<y){
      s=x;
      x=y;
      y=s;
    }
    scanf("%d",&z);
    if(x<z){
      s=x;
      x=z;
      z=y;
      y=s;
    }
    if(x>=z&&y<z){
    s=y;
    y=z;
    z=s;
}
    for(i=0;i<7;i++){
      scanf("%d",&a);
      if(a>x){
	s=x;
	x=a;
	z=y;
	y=s;
	a=0;
      }
      if(x>=a&&a>y){
	s=y;
	y=a;
	z=s;
	a=0;
      }
      if(y>=a&&z<a){
	z=a;
      }
    }
    printf("%d\n",x);
    printf("%d\n",y);
    printf("%d\n",z);
    return(0);
}

C++: #include <iostream>
#include <string>
#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 <algorithm>
using namespace std;

int main(){
  int t[10];

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