#include "bits/stdc++.h" using namespace std; #define fastcin {\ cin.tie(0);\ ios::sync_with_stdio(false);\ } int main (){ fastcin; int N; cin >> N; int L[7] = {0}; int max = 0, ans = 0; for (int i = 0; i < N; i++){ int tmp; cin >> tmp; L[tmp]++; } for (int i = 1; i < 7; i++) { if (L[i] >= max) { max = L[i]; ans = i; } } cout << ans << endl; return 0; }