#include <bits/stdc++.h>
using namespace std;
int main(void) {
  int n, d = 0, l = 0;
  string s, p, q;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> s;
    if (i == 0) p = s;
    if (p == s)
      d++;
    else {
      q = s;
      l++;
    }
  }
  if (d > l)
    cout << p << endl;
  else
    cout << q << endl;
  return 0;
}
