#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  int alpha = 1;
  int beta = 0;
  string a, b, c;
  cin >> n >> a;
  for (int i = 0; i <= n - 2; i++) {
    cin >> b;
    if (b == a) {
      alpha++;
    } else {
      c = b;
      beta++;
    }
  }
  if (alpha > beta) {
    cout << a << endl;
  } else {
    cout << c << endl;
  }
  return 0;
}
