#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, a = 1, b = 0;
  string s, s1, s2;
  cin >> n;
  cin >> s;
  for (int i = 0; i < n - 1; i++) {
    cin >> s1;
    if (s == s1)
      a++;
    else {
      b++;
      s2 = s1;
    }
  }
  if (a > b)
    cout << s;
  else
    cout << s2;
}
