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++: //
//  main.cpp
//  AizuOnlineJudge
//
//  Created by TomoyaYamaguchi on 2016/08/05.
//  Copyright ?? 2016??´ TomoyaYamaguchi. All rights reserved.
//

#include <iostream>

using namespace std;

int main(int argc, const char * argv[]) {
    // insert code here...
    int height[10];//?±±?????????
    int tmp = 0;
    int end = 0;
    
    for(int i=0;i<10;i++){
        cin >> height[i];
    }
    
    while(end == 0){
        end = 1;
        for(int i=0;i<9;i++){
            if(height[i] < height[i+1]){
                end = 0;
                tmp = height[i];
                height[i] = height[i+1];
                height[i+1] = tmp;
            }
        }
    }
    
    for(int i=0;i<3;i++){
        cout << height[i] << endl;
    }
    
    return 0;
}

C++: #include<bits/stdc++.h>

using namespace std;

int main(){
    vector<int> v;
    for(int i=0;i<10;i++){
    	int x;
    	cin >> x;
    	v.push_back(x);
    }
    sort(v.begin(),v.end());
    cout << v[9] << endl;
    cout << v[8] << endl;
    cout << v[7] << endl;
}

C++: #include<iostream>
#include<algorithm>
using namespace std;
int a[10];
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;
	getchar();
	getchar();
	return 0;
}

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

int main() {
    int height[10];
    for (int i = 0; i < 10; i++) {
        cin>>height[i];
    }
    for (int i = 0; i < 10; i++) {
        for (int j = i; j < 10; j++) {
            int max = height[i];
            int c = i;
            if (height[j] > max) {
                max = height[j];
                c = j;
            }
            int temp;
            temp = height[c];
            height[c] = height[i];
            height[i] = temp;
        }
    }
    cout<<height[0]<<endl;
    cout<<height[1]<<endl;
    cout<<height[2]<<endl;
    return 0;
}

C++: #include<stdio.h>
 
int main(void){
 
    /* 宣言と初期化 */
    int hai[10];
    int i;
    int temp2nd;
    int temp3rd;
    int tempmax;
 
for(i=0;i<10;i++)
{
printf("山の高さ　");
scanf("%d",hai[i]);
}
    /* 代入 */
    temp2nd=hai[0];
    tempmax=hai[0];
    temp3rd=hai[0];
 
    /* 計算 */
    for(i=0;i<=10;i++){
        /* 最大値求める */
        if(hai[i]>tempmax)
        tempmax=hai[i];
    }
 
    for(i=0;i<=10;i++){
        /*2番目求める */
        if(hai[i]<tempmax&&hai[i]>temp2nd)
        temp2nd=hai[i];
    }
 
    for(i=0;i<=10;i++){
        /* 3番目求める */
        if(hai[i]>temp3rd&&hai[i]<temp2nd)
        temp3rd=hai[i];
    }
 
    /* 表示 */
    printf("最も高い山の高さ　%d\n",tempmax);
    printf("２番目に高い山の高さ　%d\n",temp2nd);
    printf("３番目に高い山の高さ　%d\n",temp3rd);
 
    return 0;
}

C++: #include <iostream>
#include <stdio.h>
#define _USE_MATH_DEFINES
#include <cmath>
#include<algorithm>
using namespace std;
int main()
{
    int a[10],i;
    for(i=0;i<10;i++)cin>>a[i];
    sort(a,a+10);
    for(i=9;i>6;i--)cout<<a[i]<<endl;
    return 0;
}

C++: #include <iostream>
using namespace std;
int main(void){
    int x, rank01,rank02,rank03 = 0;
    
    for(int i = 0; i < 10; i++){
        cin >> x;
        if(rank01 < x){
            rank01 = x;
        }
        else if(rank02 < x){
            rank02 = x;
        }
        else if (rank03 < x){
            rank03 = x;
        }
    }
    
    std::cout << rank01 << std::endl;
    std::cout << rank02 << std::endl;
    std::cout << rank03 << std::endl;
    
}

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

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

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

C++: #include <iostream>
#include <cstdlib>
#include <ctime>

#define N 10

using namespace std;


bool check(int mountain[N]){
	for (int i=0; i<(N-1); ++i){
		if (mountain[i] < mountain[i+1]){
			return false;
		}
	}
	return true;
}

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){
	srand(time(NULL));
	int counter = 0;
	/*while (counter == 0){*/
		int mountain[N];
		for (int i=0; i<N; ++i){
			int tmp;
			do{
				cin >> tmp;
				/*tmp = rand() % 10001;*/
				/*cout << tmp << endl;*/
			}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;
		}
		/*if (check(mountain) == false){
			cout << "Error!" << endl;
		}
		else{
			cout << "OK" << endl;
		}
		cout << "counterの入力:";
		cin >> counter;*/
	/*}*/


	return 0;
}

C++: #include <iostream>
#include <string>
#include <utility>
#include <algorithm>
#include <queue>
#include <map>
/*
#define _CRT_SECURE_NO_WARNIGS
#pragma warning(disable:4996)
*/
using namespace std;
typedef long long I;
#define REP(i , x) for(int i = 0 ; i < x ; ++i)

int mo[10];

int f(int a){
	int l(0);
	while (a){
		a /= 10;
		l++;
	}

	return l;
}

int main()
{
	int a, b;
	while (scanf("%d %d",&a,&b)+1){
		cout << f(a+b) << endl;
	}
	return 0;
}

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

int number[10];
int count = 0;
int flag = 0;
int temp = 0;

int main(){

        for(count=0;count<10;count++){
                cin >> number[count];
                }
        count = 0;

        while(flag<10){
                for(count=0;count<9;count++){
                        if(number[count]<number[count+1]){
                                temp=number[count];
                                number[count]=number[count+1];
                                number[count+1]=tempa;
                        }
                }
                flag++;
}
        for(count=0;count<3;count++){
                cout<<number[count]<<endl;
        }
}

C++: #include<bits/stdc++.h>
const long long INF = INT_MAX / 2;
const long long MOD = 1000000007;
const long double PI = 3.1415926;
#define FOR(i,r,n) for(ll i = (ll)(r); i < (ll)(n); i++)
#define REP(i,n) FOR(i,0,n)
#define REP1(i,n) FOR(i,1,n)
#define ALL(x) x.begin(),x.end()
#define RALL(x) x.rbegin(),x.rend()
#define ll long long int
using namespace std;
ll ans = 0, sum = 0, n, k, cnt = 0, w, h;
string s;
vector<ll> v;
vector < pair<ll, ll > > vp;
vector<vector<ll> > vv(50, vector<ll>(50, INF));
vector<string> vs;
vector<char> vc;
set<ll> st;
map<char, ll> mp;

/*--------------------template--------------------*/

int main()
{
	REP(i,10)
	{
		cin >> n;
		v.push_back(n);
	}
	sort(RALL(v));
	REP(i,3)
	{
		cout << v[i] << endl;
	}
}

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

using namespace std;

int main(){
	deque<int> Mt_meter;
	for(int i = 0;i < 10;i++){
		int meter;
		cin >> meter;
		Mt_meter.push_front(meter);
	}
	sort(Mt_meter.rbegin(),Mt_meter.rend());
	for(int i = 0;i < 3;i++){
		cout << Mt_meter[i] << endl;
	}

	return 0;
}