Task: Program Execution
Input (English): 4139, J, v, 1713, 1485, 2951, 8977, l, J, 5597, 1359, L, Q, J
Output (English): 4139, 10, 22, 1713, 1485, 2951, 8977, 12, 10, 5597, 1359, 12, 17, 10