Task: Program Execution
Input (English): 2, 6, ['9985', '7149', 'P', '1119', '1375', 'S']
Output (English): S57319111P9417