Task: Text to Code
Input (English): select the row whose established record of all rows is 2nd maximum . the league record of this row is ahl .
Output (English): eq { hop { nth_argmax { all_rows ; established ; 2 } ; league } ; ahl }