Task: Text to Code
Input (English): select the row whose % of votes khuzestan record of all rows is 2nd maximum . the candidates record of this row is akbar hashemi rafsanjani .
Output (English): eq { hop { nth_argmax { all_rows ; % of votes khuzestan ; 2 } ; candidates } ; akbar hashemi rafsanjani }