import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { public static void main(String[] args) { Scanner in = new Scanner(System.in); int n = in.nextInt(); int[] birds = new int[n]; int count[] = new int[5]; for(int i=0; i < n; i++){ birds[i] = in.nextInt(); if(birds[i]==1) count[0]++; else if(birds[i]==2) count[1]++; else if(birds[i]==3) count[2]++; else if(birds[i]==4) count[3]++; else if(birds[i]==5) count[4]++; } int max = count[0]; int max_type = 1; for(int j=1; j<5; j++) { if(count[j]>max) { max = count[j]; max_type = j+1; } } System.out.println(max_type); // your code goes here } }