Task: Program Execution
Input (English): R, 5523, L, a, 6977, 745, L, 5895, 9575, 9921, 7047, 9713, r
Output (English): 5523, 6977, 745, 5895, 9575, 9921, 7047, 9713