#include "bits/stdc++.h" #define MOD 1000000007 #define INF 11234567890 #define in std::cin #define out std::cout #define rep(i,N) for(LL i=0;i> N; rep(i, N) { in >> L[i]; } for (int i = 1; i <= 6; ++i) { auto sum = (std::upper_bound(L, L + N, i) - std::lower_bound(L, L + N, i)); if (sum >= max) { max = sum, ans = i; } } out << ans << std::endl; return 0; }