#include #include using namespace std; int main(){ int n; cin >> n; vector types(n); vector results(5); for(int types_i = 0; types_i < n; types_i++){ cin >> types[types_i]; results[types[types_i]]++; } int max = -1; int max_index = 0; for (int i = 1; i <= 5; i++) { if (results[i] > max) { max_index = i; max = results[i]; } } cout << max_index << endl; return 0; }