#include <iostream>
#include <algorithm>
#include <set>
#include <map>
using namespace std;
int main() {
  int x, count[101]={}, max=0; 
  set<int> a; 
  multimap<int, int> b; 
  while(cin >> x) { 
    count[x]++;  
    a.insert(x);
  } 
  for(set<int>::iterator it=a.begin(); it!=a.end(); it++) { 
    b.insert(make_pair(count[*it], *it));   
    if(count[*it]>max) max=count[*it]; 
  } 
  for(multimap<int, int>::iterator it=b.begin(); it!=b.end(); it++) {  
    if(it->first==max) cout << it->second << endl; 
  } 
  return 0;
}
