Go: package main

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

var rdr = bufio.NewReaderSize(os.Stdin, 1000000)

func readLine() string {
	buf := make([]byte, 0, 1000000)
	for {
		l, p, e := rdr.ReadLine()
		if e != nil {
			panic(e)
		}
		buf = append(buf, l...)
		if !p {
			break
		}
	}
	return string(buf)
}

func toInt(str string) int {
	n, _ := strconv.Atoi(str)
	return n
}

func main() {
	lst := make([]int, 0)
	for i := 0; i < 10; i++ {
		lst = append(lst, toInt(readLine()))
	}
	sort.Ints(lst)
	for i := 9; i > 6; i-- {
		fmt.Println(lst[i])
	}
}

C++: #include<iostream>
using namespace std;
int main(){
	int takasa[10];
	for(int i=0;i<10;i++){
		cin>>takasa[i];
	}
	for(int i=0;i<9;i++){
		for(int j=i+1;j<10;j++){
			if(takasa[i]<takasa[j]){
				swap(takasa[i],takasa[j]);
			}
		}
	}



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





	return 0;
}

C++: #include<stdio.h>
#include<algorithm>
int main(){
    int a[10];
    for(int i=0;i<10;i++)scanf("%d",&a[i]);
    std::sort(a,a+10);
    printf("%d\n%d\n%d\n",a[9],a[8],a[7]);
}

C++: #include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std;
bool cmp(int x,int y)
{
	return x > y;

}
int main()
{
	int a[11], i = 0;
	for (i = 0; i < 10; i++)
	{
		cin >> a[i];
	}
	sort(a, a + 10,cmp);
	for ( i = 0; i < 3; i++)
	{
		printf("%d\n", a[i]);
	}
	
}

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

using namespace std;

vector<int> heights;
int input;

int main(){
 while(cin >> input) heights.push_back(input);
 sort(input.begin(), input.end());
 auto itr = input.end();
 cout << *itr << "\n" << *(itr-1) << "\n" << *(itr-2) << endl;

 return 0;
}

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

int main(){
	int height[10];
	int i , j;
	for(i=0 ; i<10 ; i++){
		cin >> height[i] ;
	}
	cout << endl;
	
	for(i=9 ; i>0 ; i--){
		for(j=0 ; j<i ; j++){
			if (height[j]>=height[j+1]){
				height[j]^=height[j+1];
				height[j+1]^=height[j];
				height[j]^=height[j+1];
			}
		}
	}
	for(i=9 ; i>6 ; i--){
		cout << height[i] << endl;
	}
	return 0;
}

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

int main()
{
  int a[11]={0};
  int i,j,maxa,maxb,maxc;
  

  for(i=0; i<10; i++){
    scanf("%d",&a[i]);
    //    maxa=max(maxa,a[i]);
  }

  for(i=0; i<10; i++){
    for(j=0; j<10; j++){
      if(a[i]>a[j]){
	swap(a[i],a[j]);
      }
    }
  }

  maxa=a[0];
  maxb=a[1];
  maxc=a[2];

  printf("%d\n%d\n%d\n",maxa,maxb,maxc);
  
  return 0;
}

C++: #include<stdio.h>

int main(){
	
	int a[3];
	int o, j;

	a[0] = a[1] = a[2] = 0;
	
	for(j = 0; j < 9; j++){
		
		scanf("%d\n",&o);
		
		if(o == 0){
			
			continue;
			
		}
		
		if(a[0] < o){
			
			a[2] = a[1];
			a[1] = a[0];
			a[0] = o;
			
		}else if(a[1] < o){
			
			a[2] = a[1];
			a[1] = o;
			
		}else if(a[2] < o){
			
			a[2] = o;
			
		}
		
	}
	
	printf("%d\n", a[0]);
	printf("%d\n", a[1]);
	printf("%d\n", a[2]);
	
    return 0;
}

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

int main(){
	int mountains[9] = {};

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

	for(int i = 0; i < 10; i++){
		int maxIndex = 0;
		for(int j = 0; j < 10; j++){
			if(mountains[maxIndex] < mountains[j]){
				maxIndex = j;
			}
		}
		cout << mountains[maxIndex] << endl;
		mountains[maxIndex] = -1;
	}

	return 0;

}

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

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

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

C++: #include <iostream>
 
 
void Sort(int* a){
int tmp;
for(int i=0;i<10;i++){
for(int j=0;j<9;j++){
if(a[j]<a[j+1]){
tmp = a[j+1];
a[j+1]=a[j];
a[j] = tmp;
}
}
}
}
 
 
 
int main(){
 
int a[10];
 
for(int i=0;i<10;i++){
std::cin >> a[i];
}
Sort(a);
 
std::cout << a[0] << std::endl;
std::cout << a[1] << std::endl;
std::cout << a[2] << std::endl;
 
 
}

C++: #include<iostream>
#include<stdio.h>
#include<algorithm>
using namespace std;
int main()
{
    int s[11],i;
    for(i=0;i<10;i++){
        scanf("%d",&s[i]);
    }
    sort(s,s+10);
    for(i=9;i>6;i--){
        printf("%d\n",s[i]);
    }
 return 0;
}

C++: #include<iostream>
using namespace std;
int main()
{
    int a[10],b[3],c,d,i,j,s=0;
    for(i=0;i<10;i++)
    {
        cin >> a[i];
    }
    for(d=0;d<3;d++)
    {
    for(j=0;j<10;j++)
    {
        if(a[j]>s)
        {
            s=a[j];
            c=j;
        }
    }
    cout<<s<<endl;
    a[c]=0;
    s=0;
    }
    return 0;
}

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

int main(){
    vecctor<int> v;
    int num;
    for(int i = 0;i<10;i++){
        cin>>num;
        v.push_back(num);
    }

    sort(v.end(),v.begin(),greater<int>());
    


    for(int i = 0;i<3;i++)
        cout<<v.at(i);
    return 0;
}

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

}

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

int main() {
	int h[10];
	int rank[3];
	for(int i = 0; i < 3; i++){
		rank[i] = 0;
	}
	for(int i = 0; i < 10; i++){
		cin >> h[i];
	}
	for(int i = 0; i < 10; i++){
		if(h[i] >= rank[0]){
			rank[2] = rank[1];
			rank[1] = rank[0];
			rank[0] = h[i];
		} else if(h[i] >= rank[1]) {
			rank[2] = rank[1];
			rank[1] = h[i];
		} else if(h[i] >= rank[2]){
			rank[2] = h[i];
		}
	}
	for(int i = 0; i < 3; i++){
		cout << rank[i] << endl;
	}
	return 0;
}

C++: #include <iostream>
#include <algorithm>
using namespace std;
    
int main(){
	int data,m[10];

	while(cin >> data)
	{
		for (int j=0;j<=9;j++){
			
			if (data<=10000 && data >= 0) 
			m[j]=data;
		}


for (int j=0;j<=9;j++){
for (int i=0;i<=9;i++){

	if (m[i] <= m[i+1])
		std::swap(m[i],m[i+1]);

}
}
 
for (int i=0;i<=9;i++){
cout <<  m[i] <<'\n';
}

    return 0;
}

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

using namespace std;

int main(void)
{
	
	int n;
	int Max1,Max2,Max3;
	Max1=0;
	Max2=0;
	Max3=0;
	
	for(int i=0;i<=9;i++){
		cin>>n;
		if(n>=Max1){
			Max3=Max2;
			Max2=Max1;
			Max1=n;
		}
		else if(n>=Max2){
			Max3=Max2;
			Max2=n;
		}
		else if(n>=Max3){
			Max3=n;
		}
		else{
		}
		/*cout<<Max1<<endl;
		cout<<Max2<<endl;
		cout<<Max3<<endl;*/
	}
	cout<<Max1<<endl;
	cout<<Max2<<endl;
	cout<<Max3<<endl;
}

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

int main(){
int a[10];

for(int i=0;i<10;i++){
scans(" %d",&a[i]);
}

sort(a,a+10);

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

return 0;
}

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