Task: Program Execution
Input (English): 5877, 217, 1531, 3153, r, 5987, 8561, 2249, p, D, 8307, 3895, v, R, Y, N, 5319, 6971, 6515, 8633, 853, 4675, d, P
Output (English): 5877, 217, 1531, 3153, 18, 5987, 8561, 2249, 16, 4, 8307, 3895, 22, 18, 25, 14, 5319, 6971, 6515, 8633, 853, 4675, 4, 16