#include using namespace std; int main(){ int n; cin >> n; vector types(n); for(int types_i = 0; types_i < n; types_i++){ cin >> types[types_i]; } // your code goes here vector cnts(5); for (int x: types) { cnts[x-1]++; } int maxval=0, maxidx=0; for (int i=0; i<5; i++) { if (cnts[i] > maxval) { maxidx = i+1; maxval = cnts[i]; } } cout << maxidx; return 0; }