Task: Program Execution
Input (English): 2, 4, ['H', '4221', '5493', 'D', '9469', '4417', 'd', 'p', '1305', '1371', '1115', '8301', '7093', 'M', '7541', 'H']
Output (English): 4221, 4417, 1371, M