Task: Program Execution
Input (English): g, 685, 4523, X, X, 4787
Output (English): 2, 3, 6