Task: Program Execution
Input (English): 2, 22, ['E', '9437', 'R', 'M', 'p', 'A', '7261', '4163', '8357', '6555', 'I', 'T', '5471', 'G', 'S', '3447', 'C', '5845', 'I', '3817', 'p', '6781']
Output (English): 6781p3817I5845C3447SG5471TI6555835741637261ApMR9437