Task: Program Execution
Input (English): i, M, N, S, 4627, 5419, N, U, r, Q, 8329
Output (English): 5, 6, 11