#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  string one, o, two;
  vector<int> a(2, 0);
  cin >> n;
  cin >> one;
  a[0] += 1;
  while (n-- > 1) {
    cin >> o;
    if (o == one)
      a[0] += 1;
    else {
      a[1] += 1;
      two = o;
    }
  }
  if (a[0] > a[1])
    cout << one;
  else
    cout << two;
  return 0;
}
