Task: Program Execution
Input (English): 2, 5, ['1431', 'L', 'g', 'R', '1431', 'e', 'q', '4701']
Output (English): LgR1431