Task: Program Execution
Input (English): 3, 3, ['9381', '5051', '3603', 'D', 'w', 'P', '3647', '7125', '4801', '4585', 'S', 'x']
Output (English): 3603