Task: Program Execution
Input (English): n, A, q, 1583
Output (English): 14, 1, 17, 1583