import java.util.*; public class Main{ static StringBuilder sb = new StringBuilder(""); public static void main(String[] args) { Scanner sc = new Scanner(System.in); int H1 =sc.nextInt(); int N =sc.nextInt(); int n = (N-1); int[] H = new int[N]; for (int i=0;iH[0]) { System.out.println("1st"); }else if(H1>H[1]){ System.out.println("2nd"); }else if (H1>H[2]) { System.out.println("3rd"); }else{ System.out.println(N+"th"); } } }