Task: Program Execution
Input (English): 3361, 7223, g, 831, 855, N, Q, Q, 8705
Output (English): 1, 2, 4, 5, 9