Go: package main

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

var scanner = bufio.NewScanner(os.Stdin)

func nextInt() int {
	scanner.Scan()
	i, e := strconv.Atoi(scanner.Text())
	if e != nil {
		panic(e)
	}
	return i
}
func main() {
	heighs := make([]int, 10)
	for i := range heighs {
		heighs[i] = nextInt()
	}
	sort.Sort(sort.Reverse(sort.IntSlice(heighs)))
	for i := 0; i < 3; i++ {
		fmt.Println(heighs[i])
	}
}

C++: #include <iostream>
using namespace std;
  
int main()
{
    int array[10];
      
    for(int i=0; i<10; i++)
        cin>>array[i];
    
    for(i=0; i<9; i++){
        for(int j=i+1; j<10; j++){
            if(array[i]<array[j]){
                int tmp=array[i];
                array[i]=array[j];
                array[j]=tmp;
            }
        }
    }
    
    for(i=0; i<3; i++)
        cout<<array[i]<<"\n";
    
    return 0;
}

C++: #include <stdio.h>

int main(){
  int a[10], max, maxidx;
  for(int i=0; i<=9; i++){
    scanf("%d", &a[i]);
  }
  for(int j=0; j<3; j++){
    max = -1;
    for(int i=0; i<=9; i++){
      if(a[i] > max){
	max = a[i];
	maxidx = i;
      }
    }
    printf("%d", max);
    a[maxidx] = -1;
  }
}

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

using namespace std;

int main()
{
	vector<int> mountains;

	for (int i = 0; i < 10; i++){
		int mountain;
		scanf("%d", &mountain);
		mountains.push_back(mountain);
	}
	sort(mountains.begin(), mountains.end());
	for (int i = 0; i < 3; i++)
		printf("%d\n", mountains[9 - i]);

	return (0);
}

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

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

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

  sort(a,a+10);

  for(i=9;i>=7;i--){
    cout << a[i] << endl;
  }
}

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

int main_test()
{
	string str;
	cout << "あなたの名前を入力してください" << endl;
	cin >> str;
	cout << str <<"さんよろ"<<endl;

	return 0;
}

C++: #include <iostream>

using namespace std;

int main() {
	const int len = 10;
	int arr[len];

	for (int i = 0; i < len; i++)
		cin >> arr[i];

	for (int i = 0; i < len; i++)
		for (int j = 0; j < len; j++)
			if (arr[i] < arr[j])
				swap(arr[i], arr[j]);

	cout << endl;

	for (int i = len - 1; len - 4 < i; i--)
		cout << arr[i] << endl;

	return 0;
}

C++: #include<stdio.h>
int main(void) {
	int i, mountain[10],x,y;
	int n = 0;
	int l = 0;
	int m = 0;
	for (i = 0;i < 10;i++) {
		scanf("%d", &mountain[i]);
	}
	for (i = 0;i < 10;i++) {
		if (mountain[i] > m) {
			m = mountain[i];
			x = i;
		}
	}
	printf("%d\n", m);
	for (i = 0;i < 10;i++) {
		if (i == x) {}
		else {
			if (mountain[i] > n) {
				n = mountain[i];
				y = i;
			}
			
		}
	}
	printf("%d\n", n);
	for (i = 0;i < 10; i++) {
		if (i == y || i == x) {}
		else {
			if (mountain[i] > l) {
				l = mountain[i];
			}
		}
	}
	printf("%d\n", l);

	return 0;
}

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

using namespace std;

main(){
	int i, j;
	int data[10] = {0};
	int buf;

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

	for(j = 0; j < 10; j++){
		for(i = 10; i > 0; i--){
			if(data[i] > data[i - 1]){
				buf = data[i - 1];
				data[i - 1] = data[i];
				data[i] = buf;
			}
		}
	}

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

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

int main(void)
{
    vector <int> a;
    int b;

    for (int i = 0; i < 10; i++){
    cin>>b;
a.push_back(b);
}

for (int i = 0; i < 100000; i++){
	for (int j = 0; j < 10000; j++){
		b = 0;
	}
}

sort(a.begin(), a.end());
cout << a[9] << endl << a[8] << endl << a[7] << endl;

return 0;
}

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

int main(){

 int f, s, t, i, x;

 f = s = t = 0;

 for (i = 0; i < 10; i++) {
  cin >> x;

  if (x > f) {
   t = s;
   s = f;
   f = x;
  } else if (x > s) {
   t = s;
   s = x;
  } else if (x > t) {
   t = x;
  }
 }

 cout << f << "\n" << s << "\n" << t << "\n";

 return 0;
}

C++: #include <stdio.h>
#include <iostream>

int nList[10],nGet,nSave[4]; // Variables

int main() {
    for (int i=0;i<10;i++){// Until 10 integers are set
        scanf("%i",&nGet); // Reads input
        if (nGet>0&&nGet<10000){ // Making sure the number inputted is greater than 0 and less than 10,000
        nList[i]=nGet; //
    }}


for (int sN=0;sN<3;sN++){

for (int rN=0;rN<10;rN++){

if (nList[rN]>nSave[sN]&&nSave[sN]==0){
    nSave[sN]=nList[rN];
    nList[rN]=0;}
if (nList[rN]>nSave[sN]&&nSave[sN]!=0){
        nSave[sN+1]=nSave[sN];
        nSave[sN]=nList[rN];
        nList[rN]=0;}

        }
    }


printf("%i\n%i\n%i",nSave[0],nSave[1],nSave[2]); // Shows the stored numbers
}

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

	long int a[10], i, j, b, max1, max2, max3;

	cout << "\n";

	for (i = 0; i < 10; i++)
		cin >> a[i];

	for (j = 0; j < 9; j++)
	for (i = 0; i < 9 - j; i++)
	if (a[i] > a[i + 1])
	{
		b = a[i];
		a[i] = a[i + 1];
		a[i + 1] = b;
	}

	max1 = a[0];
	max2 = a[1];
	max3 = a[2];
	cout << max1 << "\t";
	cout << max2 << "\t";
	cout << max3 << endl;
		return 0;
		/*Javad SHeybani*/

	}

C++: #include <iostream>

using namespace std;

int main()
{
	int i,moun,high[10000];
	int j=0;
	for(i=0;i<10000;i++)
	{
		high[i] = 0;
	}
	for(i=0;i<10;i++)
	{
		cin >> moun;
		high[moun] = 1;
	}
	for(i=9999;i>0;i--)
	{
		if(high[i] == 1)
		{
			cout << i << endl;
			j++;
		}
		if(j == 3)
		{
			break;
		}
	}
	return 0;
}

C++: #include <iostream>
#include <vector>
#include <string>
#include <fstream>
#include <list>
#include <cmath>
#include <fstream>
#include <queue>
#include <sstream>
#include <algorithm>
#include <cstring>
using namespace std;
template <class T> void change(T &a, T &b)// 交&#25442;
{
	T temp;
	temp = a;
	a = b;
	b = temp;
}
template <class T> void quicksort(vector<T> &S,int a,int b) // 快速排序
{
     int x = a;
	 int y = b;
	 T mid = S[(a+b)>>1];
     while (x <= y)
     {
           while (S[x] < mid) x++;
           while (S[y] > mid) y--;
           if (x <= y)
           {
              change(S[x], S[y]);
              x++;
              y--;
           }
     }
     if (x < b) quicksort(S, x, b);
     if (y > a) quicksort(S, a, y);
}
vector<int> vi;
int main()
{
	vi.resize(10);
	for(int i = 0; i < 10; i++)
		cin >> vi[i];
	quicksort(vi,0,9);
	cout << vi[9] << endl;
	cout << vi[8] << endl;
	cout << vi[7] << endl;
	return 0;
}

C++: #include "bits/stdc++.h"
using namespace std;

int main()
{
   long long int N, Case = 0;
   vector <long int> V;
   for(int i = 0; i < 10; i++)
   {
     long int Temp; cin >> Temp; V.push_back(Temp);
   }
   sort(V.rbegin(),V.rend());
   cout << V[0] << endl << V[1] << endl << V[2] << endl;
   return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef vector<string> vs;
typedef vector<bool> vb;
typedef vector<char> vc;
typedef vector<ll> vll;
typedef vector<vector<int>> vvi;
typedef vector<vector<string>> vvs;
typedef vector<vector<char>> vvc;
typedef vector<vector<bool>> vvb;
typedef pair<int,int> P;
#define vrep(v,n) for(int i=0;i<n;i++){cin >> v.at(i);} //配列vにn個の要素を入力する
#define rep(i, l, n) for (int i = l; i < (int)(n); i++)
#define repn(i, l, n) for (int i = l; i <= (int)(n); i++)
#define pb push_back 

const int mod = 1000000007;
const int inf = 1e9;

int main(){
    vi m(10);
    rep(i,0,10){
        cin >> m[i];
    }
    sort(m.rbegin(), m.rend());
    rep(i,0,3){
        cout << m[i] << endl;
    }
    
}

C++: #include<stdio.h>
int main()
{
    int a[50],i;
    while(scanf("%d\n",&a[i])!=EOF)
    {
        int t,j;
        for(i=0; i<9; i++)
        {
            for(j=1; j<10; j++)
            {
                if(a[i]<a[j])
                {
                    t=a[i];
                    a[i]=a[j];
                    a[j]=t;
                }
            }
            for(i=0; i<4; i++)

                printf("%d\n",a[i]);
        }
    }
    return 0;
}