Task: Program Execution
Input (English): 3, 7, ['4187', 'v', '6709', 'F', '1781', 'M', '3419']
Output (English): 3419, M, 1781, F, 6709