#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, b = 0;
  string a[10], x[101];
  cin >> n >> x[0];
  for (int i = 1; i < n; i++) {
    cin >> x[i];
    if (x[i] == x[0]) b++;
  }
  b++;
  if (b > n / 2) {
    cout << x[0];
    return 0;
  }
  for (int i = 0; i < n; i++) {
    if (x[i] != x[0]) {
      cout << x[i];
      return 0;
    }
  }
  return 0;
}
