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

int main() {
  int N ;
  vector<int>Muntain(N);
  for(int i = 0; i < N; i++){
    cin >> Mountain(i);
  }
  sort(Mountain.begin(), Mountain.endl());

  for(int j = 0; j < 3; j++){
    cout << Mountain(j) << endl;
  }
    }
  }
}

