Task: Program Execution
Input (English): 3117, 4687, 7113, b, e, 2195, g, 5389, M, q, g, M, 7433, 5805, N
Output (English): b, e, g, M, q, g, M, N