Task: Program Execution
Input (English): 4773, 3505, 1481, N, K
Output (English): 4, 5