Task: Program Execution
Input (English): 9841, 9823, 7361, 285, 6167, g, r, r, 7443, r, w, 1581, W
Output (English): 6, 7, 8, 10, 11, 13