Task: Program Execution
Input (English): N, 1477, Z, 7015, C, 9071
Output (English): 3