#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]; } int birds[5] = {0}, bird, counter, largest_flock = 0, highest_frequency = 1; for (counter = 1; counter <= n; counter++) birds[types[counter-1]-1]++; for (bird = 0; bird < n; bird++) { if (birds[bird] > largest_flock) { largest_flock = birds[bird]; highest_frequency = bird +1; } } cout << highest_frequency; return 0; }