Task: Program Execution
Input (English): 5, 11, ['K', '1147', '2629', 'n', '3983', 'Q', 'S', 'Q', '589', 'i', 'r', '4777']
Output (English): ri985QSQ3893