Task: Program Execution
Input (English): j, 1861, 529, m, N, 2861, 4131, 6451, 6347, p, N, 183
Output (English): 10, 1861, 529, 13, 14, 2861, 4131, 6451, 6347, 16, 14, 183