#include #include #include #include #define READ_BUFSIZE ( 1024 ) #define READ_DELIMITER ( " " ) int main(int argc, char *argv[]) { /* char szRead[READ_BUFSIZE] = ""; int OutList[1] = { 0 }; //char* pOutList[2] = {0}; split( szRead, READ_BUFSIZE, READ_DELIMITER, OutList); int N = OutList[0]; int* pOutList2 = new int[N]; char* pszRead = new char[N * 2]; split(pszRead, N * 2, READ_DELIMITER, pOutList2); */ int N = 0; scanf("%d", &N); int Level[7] = { 0 }; //レベル毎にカウントする int idx = 0; for (int i = 0; i < N; i++) { scanf("%d", &idx); Level[idx]++; } int max = Level[0]; int mid = 0; for (int j = 1; j <= 6; j++) { if (max <= Level[j]) { max = Level[j]; mid = j; } } printf("%d\n", mid); return 0; }