Task: Program Execution
Input (English): 1781, F, 4399, 5235, 7839, K, c, 6617, 7165, x, 1833, 5777, 4089, m
Output (English): 1781, 4399, 5235, 7839, 6617, 7165, 1833, 5777, 4089