Task: Program Execution
Input (English): N, V, 8587, 5133
Output (English): 14, 22, 8587, 5133