#include <cstdio>
#include <algorithm>
using namespace std;
pair<int, int> p[101];
bool comp(const pair<int, int> &a, const pair<int, int> &b) {
    if (a.second == b.second) return a.first < b.first;
    return a.second > b.second;
}
int main(){
    int n;
    for (int i = 0; i <= 100; i++) p[i] = {i, 0};
    while(scanf("%d", &n) != EOF) {
        p[n].second++;
    }
    sort(p, p+101, comp);
    int minv = p[0].second;
    for (int i = 0; i <= 100; i++) {
        if (p[i].second < minv) break;
        printf("%d\n", p[i].first);
    }
}

