Task: Program Execution
Input (English): 2, 5, ['T', 'P', '1075', '9771', 'n', 'w', '7833']
Output (English): n17795701P