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>
#include<array>
#include<algorithm>
int main(void){
std::array<int,10> h;
int tmp;
for(auto& e : h){
std::cin>>e;
}
std::sort(h.begin(),h.end());
for(int i=0;i<3;i++){
std::cout<<h[i]<<std::endl;
}

return 0;
}

C++: #include <stdio.h> #include <functional> #include <algorithm>int main(){ int mt[10], i; std::sort(mt, mt + 10, std::greater<int>); for (i = 0; i < 3; i++) printf("%d", mt[i]);return 0; }

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

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

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

int main()
{
	int i, h;
	int mh[3] = {0};

	for(i=0;i<10;i++){

		cin>>h;
		if(0<=h && h<=10000)
		if(mh[0] < h) mh[0] = h;
		else if(mh[1] < h) mh[1] = h;
		else if(mh[2] < h) mh[2] = h;

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


	return 0;
}

C++: #include<iostream>
#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;

//??\?????????
void swap(int *a, int *b){
	int temp = *a;
	*a = *b;
	*b = temp;
}

int main(){
	int str,mt[10];
	int i;
	
	for(i=0;i<10;i++){
		cin >> str;
		mt[i] = str;
	}
	
	// sort
	int num = 1;
	while(num<=3){
		str = mt[num-1];
		for(i=num;i<10;i++){
			if(str<mt[i]){
				str = mt[i];
				swap(mt[num-1],mt[i]);
			}
		}
		cout << mt[num-1] << "\n";
		num++;
	}
	
	return 0;
}

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

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

C++: #include <iostream>
int main(){
	int a,b,c;
		for(a=1;a<10;++a){
			for(b=1;b<10;++b){
				c=a*b;
				std::cout<<a<<"x"<<b<<"="<<c<<std::endl;
				}
		}
	 return 0;
	}

C++: #include <iostream>
#include <cmath>
#include <cstdio>
#include <algorithm>
#include <vector>
#include <sstream>
#include <string>
#include <cstdlib>
using namespace std;

template <class T> int streamvar(std::istream& in, T& var)
{
    if (!in) {
        return 1;
    }
    in >> var;
    if (in.fail()) {
        return 1;
    }
    return 0;
}
template <class T> int streamvec(std::istream& in, std::vector<T> &v)
{
    v.clear();
    string s;

    if (!in) {
        return 1;
    }
    getline(in, s);
    if (in.fail()) {
        return 1;
    }
    istringstream is(s);
    while (1) {
        T tmp;
        is >> tmp;
        if (is.fail())
            break;
        v.push_back(tmp);
    }
    return 0;
}

int main(void)
{
    vector<int> v;
    int tmp;
    while (!streamvar(cin, tmp)) {
        v.push_back(tmp);
    }
    sort(v.begin(), v.end(), greater<int>());
    for (int i = 0; i < 3; i++) 
        cout << v[i] << endl;
    return 0;
}

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

int main(void) {
    int height[10];
    
    for(int i = 0; i < 10; ++i) {
        while(!(0 <= height[i] && height[i] <= 10000)) {
            cout << "No." << i + 1 << " : " << flush;
            cin >> height[i];
        }
    }
    sort(height, height + 10);
    
    for(int i = 0; i < 3; ++i) {
        cout << height[9 - i] << endl;
    }
}

C++: #include<iostream>
#include<cstdio>
#include<cstring>
#include<algorithm>
#define S 10
using namespace std;

int main(){
    int arr[S];

    for(int i=0;i<S;i++)
        cin>>arr[i];
    sort(arr,arr+S);
    //cout<<endl;
    for(int i=S-1;i>=S-3;i--)
        cout<<arr[i]<<endl;

return 0;
}

C++: /*
    AOJ Volume0 0001

        List of Top 3 Hills
        There is a data which provides heights (in meter) of mountains. The data is only for ten mountains.
        Write a program which prints heights of the top three mountains in descending order.


        Input
            Height of mountain 1
            Height of mountain 2
            Height of mountain 3
             .
             .
            Height of mountain 10



        Constraints
            0 ≤ height of mountain (integer) ≤ 10,000



        Output
            Height of the 1st mountain
            Height of the 2nd mountain
            Height of the 3rd mountain



        Sample Input 1
            1819
            2003
            876
            2840
            1723
            1673
            3776
            2848
            1592
            922

        Output for the Sample Input 1
            3776
            2848
            2840

        Sample Input 2
            100
            200
            300
            400
            500
            600
            700
            800
            900
            900
    
        Output for the Sample Input 2
            900
            900
            800
    
*/

#include <iostream>


namespace aoj
{
    class bigger_int_storage
    {
    private:
        int _size;
        int* _buffer;

    public:
        bigger_int_storage(int size);
        ~bigger_int_storage();
        void push(int value);
        int operator[](int idx)const;
    };
}



int main(void)
{
    aoj::bigger_int_storage bs(3);

    for(int i=0; i<10; ++i)
    {
        int input;
        std::cin >> input;
        bs.push(input);

        /*

        // confirming : 
        std::cout << std::endl;
        std::cout << "[current] -----" << std::endl;
        std::cout << bs[0] << std::endl;
        std::cout << bs[1] << std::endl;
        std::cout << bs[2] << std::endl;
        */
    }

    std::cout << bs[0] << std::endl;
    std::cout << bs[1] << std::endl;
    std::cout << bs[2] << std::endl;

    return 0;
}




aoj::bigger_int_storage::bigger_int_storage(int size)
{
    _size = size;
    _buffer = new int[_size];
    for(int i=0; i<_size; ++i)
        _buffer[i] = -2147483648;
}

aoj::bigger_int_storage::~bigger_int_storage()
{
    delete[] _buffer;
}

void aoj::bigger_int_storage::push(int value)
{
    for(int i=0; i<_size; ++i)
    {
        if(value > _buffer[i])
        {
            for(int j=_size-1; j>i; --j)
                _buffer[j] = _buffer[j-1];

            _buffer[i] = value;
            break;
        }
    }
}

int aoj::bigger_int_storage::operator[](int idx)const
{
    return _buffer[idx];
}