Task: Program Execution
Input (English): 2967, 1077, 1295, M, 1631, f, 7415, d, 3159, 4715, K, g, 1419, i, e, S, 3627, 6405, p, 57
Output (English): 1, 2, 3, 5, 7, 9, 10, 13, 17, 18, 20