Task: Program Execution
Input (English): 3, 5, ['d', 'g', '3029', 'C', 'M', '4075']
Output (English): M, C, 3029