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) { int type1=0,type2=0,type3=0,type4=0,type5=0,id=0; Scanner in = new Scanner(System.in); int n = in.nextInt(); int[] types = new int[n]; for(int types_i=0; types_i < n; types_i++){ types[types_i] = in.nextInt(); if(types[types_i]==1){ ++type1; } else if(types[types_i]==2){ ++type2; } else if(types[types_i]==3){ ++type3; } else if(types[types_i]==4){ ++type4; } else if(types[types_i]==5){ ++type5; } } // System.out.println("1"+type1); // System.out.println("2"+type2); //System.out.println("3"+type3); //System.out.println("4"+type4); //System.out.println("5"+type5); // for(int i=0;i=type2 && type1>=type3 && type1>=type4 && type1>=type5){ id=1; // System.out.println("type1"+id); } else if(type2>type1 && type2>=type3 && type2>=type4 && type2>=type5){ id=2; // System.out.println("type2"+id); } else if(type3>type1 && type3>type2 && type3>=type4 && type3>=type5){ id=3; // System.out.println("type3"+id); } else if(type4>type1 && type4>type2 && type4>type3 && type4>=type5){ id=4; //System.out.println("type4"+id); } else if(type5>type1 && type5>type2 && type5>type3 && type5>type4){ id=5; //System.out.println("type5"+id); } // System.out.println("In Else"); //} System.out.println(id); } }