Go: package main

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

func main() {
        fp := os.Stdin
        scanner := bufio.NewScanner(fp)
        var lst [3]int

        for scanner.Scan() {
                num, _ := strconv.Atoi(scanner.Text())
                if lst[0] < num {
                        lst[2] = lst[1]
                        lst[1] = lst[0]
                        lst[0] = num
                } else if lst[1] < num {
                        lst[2] = lst[1]
                        lst[1] = num
                } else if lst[2] < num {
                        lst[2] = num
                }
        }

        for _, i := range lst {
                fmt.Printf("%d\n", i)
        }
}

C++: #include <iostream>

int mt[] = {
1819,
2003,
876,
2840,
1723,
1673,
3776,
2848,
1592,
922
};

int main() {
	int limit = 10000;
	for ( int j = 0; j < 3; j++ ) {
		int max = 0;
		for ( int i = 0; i < 10; i++ ) {
			if ( max < mt[ i ] && mt[ i ] < limit ) {
				max = mt[ i ];
			}
		}
		std::cout << max << std::endl;
		limit = max;
	}
}

C++: #include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    int height[10];
    for(int i=0;i<10;i++)
    {
        scanf("%d",&height[i]);
    }
    int temp;
    for(int i=0;i<10;i++){
            for(int j=i+1;j<=10;j++){
        if(height[i]<height[j]){
                temp=height[i];
            height[i]=height[j];
            height[j]=temp;
        }

            }

    }

for(int i=0;i<3;i++){
    printf("%d\n",height[i]);
}
    return 0;
}

C++: #include <cstdio>
int main(){
    int input;
    int i;
    scanf("%d",&input);
    int first=0,second=0,third=0;
    for(i=0;i<9;++i){
        scanf("%d",&input);
        if(input>first){
            third=second;
            second=first;
            first=input;
        }
        else if(input>second){
            third=second;
            second=input;
        }
        else if(input>third){
            third=input;
        }
    }
    printf("%d\n%d\n%d\n",first,second,third);
    return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <stdio.h>
#define pri(dt) printf("%d\n",dt)
#define RPE0(loopTotal)  for(int i=0;i<=(loopTotal);i++)
#define RPE(loopTotal)  for(int i=1;i<=(loopTotal);i++)

int data[9];

using namespace std;
int main(void){
    
    RPE0(9) scanf("%d",&data[i]);
    sort(data,data+9,greater<int>());
    RPE0(2) pri(data[i]);
    data[9] = {};
}

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

#define BOGO 10

using namespace std;

int main()
{
	int arr[BOGO];
	
	for(int i = 0; i < BOGO; i++){
		cin >> arr[i];
	}
	
	for(;;){
		
		/**
		for(int j = 0; j < BOGO; j++){
			cout << arr[j] << flush;
		}
		cout << endl;
		/**/
		
		bool found = true;
		for(int j = 0; j < BOGO-1; j++){
			if(arr[j] > arr[j+1]){
				found = false;
				break;
			}
		}
		
		if(found){
			break;
		}
		random_shuffle(arr, arr+BOGO);
	}
	cout << arr[9] << "\n" << arr[8] << "\n" << arr[7] << endl;
}

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

int main() {
	vector<int> h(10);
	for (int i = 0; i < 10; i++) {
		cin >> h[i];
	}
	sort(h.begin(), h.end(),greater<int>());
	for (int i = 0; i < 3; i++) {
		cout << h[i] << endl;
	}
	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 < 3; 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>
#include<algorithm>
using namespace std;
int d[11];
int main(){
	
	for(int i=0;i<10;i++)scanf("%d",d+i);
	std::sort(d,d+10);
	printf("%d\n%d\n%d\n",d[9],d[8],d[7]);
}

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];
  maxb=a[2];

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

C++: #include <iostream>

using namespace std;

int main(void)
{
	int input[10];

	for(int i = 3; i < 10; i++){
		for(int j = 0; j < 3; j++){
			if(input[i] > input[j]){
				swap(input[i], input[j]);
				break;
			}
		}
	}

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


	return 0;
}

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

int main(){
  int x, m1=0, m2=0, m3=0;

  for (int i=0; i<10; i++){
    cin >> x;
    if (x>m1){
      m3=m2; m2=m1; m1=x;
    } else if (x>m2){
      m3=m2; m2=x;
    } else if (x>m3){
      m3=x;
    }
  }

  cout << m1 << endl << m2 << endl << m3 << endl;

  return 0;
}

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

int main()
{
  int high;
  int temp1,temp2;
  int first=0,second=0,third=0;
  
  for(int i=0;i<10;i++){
    cin>>high;
    if(high>first){
      temp1=first;
      first=high;
      temp2=second;
      second=temp1;
      third=temp2;
    } else if (first>=high && high>second){
      temp2=second;
      second=high;
      third=temp2;
    } else if (second>=high && high>third){
      third=high;
    }
  }

  cout<<first<<endl;
  cout<<second<<endl;
  cout<<third<<endl;
  
  return 0;
}

C++: #include <iostream>
#include <string>
#include <iomanip>
#include <cmath>
#include <cstdio>
#include <algorithm>
using namespace std;
#define ff first
#define ss second
#define pi 3.14159
int main()
{
    int arr[10];

    int i;

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

     sort(arr, arr+10, greater<int>());

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

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

C++: #include <iostream>

#define NUM 4

using namespace std;

int main(){

	int A[NUM+1];
	int b;
	int i;

	for(i=0;i<=NUM;i++) {
		cout <<"?±±????????????" ;
		cin >> A[i];
		cout <<endl;
	}
	for(i=0;i<NUM;i++){
		if(A[i]>A[i+1]){
			b = A[i+1];
			A[i+1] =A[i];
			A[i] = b;

		}
	}
	

	for(i=0;i<NUM+1;i++) {
		printf("%d??????????±±????????????%d??§???",i+1,A[i]);
	}
	return 0;
}

C++: #include<stdio.h>
int main(void){
	int d, m1 = 0, m2 = 0, m3 = 0, i;{
	scanf("%d", &d);
		for(i=1;i<10;i++){
			scanf("%d", &d);
			if(d > m1){
			m3 = m2;
			m2 = m1;
			m1 = d;
				}else if(d > m2){
				m3 = m2;
				m2 = d;
					} else if(d > m3){
					m3 = d;
					}
		}
	printf("%d\n""%d\n""%d\n", m1, m2, m3);
	return 0;
}
}

C++: #include <iostream>
using namespace std;
int main() {
int a[10];
int b;
for(int i=0;i<10;i++){
cin>>b;
a[i]=b;
}
sort(a,a+10,greater<int>());
cout<<a[0]<<endl;
cout<<a[1]<<endl;
cout<<a[2]<<endl;
return 0;
}

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

int main() {
	multiset<int, greater<int>> ms; int temp;
	for (int i = 0; i < 10; i++) { cin >> temp; ms.insert(temp); }
	auto itr = ms.begin();
	for (int i = 0; i < 3; i++) { cout << *itr << endl; itr++; }
	return 0;
}

C++: #include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>
#include <ctime>
#include <cctype>
#include <climits>
#include <iostream>
#include <string>
#include <vector>
#include <map>
#include <list>
#include <queue>
#include <deque>
#include <algorithm>
#include <numeric>
#include <utility>
#include <complex>
#include <memory>
#include <functional>
using namespace std;
int main(){
	int dat[11]={};
	for(int i=0;i<10;i++){
		cin>>dat[i];
	}
	sort(dat,dat+10,greater<int>());
	cout<<dat[0]<<endl<<dat[1]<<endl<<dat[2]<<endl;
	return 0;
}