#define _GLIBCXX_DEBUG #include using namespace std; int main() { int H, N; cin >> H >> N; int rank = N; for(int i = 0; i < N-1; i++){ int I; cin >> I; if(I < H) rank--; } cout << rank; switch(rank){ case 1: cout << "st" << endl; break; case 2: cout << "nd" << endl; break; case 3: cout << "rd" << endl; break; default: cout << "th" << endl; break; } }