Task: Program Execution
Input (English): 3, 2, N, 1, p
Output (English): [['3', '2', 'N', '1'], ['3', '2', 'N', 'p'], ['3', '2', '1', 'p'], ['3', 'N', '1', 'p'], ['2', 'N', '1', 'p']]