#include <iostream>
using namespace std;

/** Problem0028 : Mode Value **/
int main()
{
	int num[101] = {0}, max=0, input;
	while (cin >> input) {
		if (++num[input] > max)
			max = num[input];
	}
	for (int i=0; i<101; i++) {
		if (num[i] == max)
			cout << i << endl;
	}
	return 0;
}