Task: Program Execution
Input (English): X, a, a, b, 5863, A, N, 6717, 2509
Output (English): 5, 8, 9