Task: Program Execution
Input (English): 1, 7, ['x', '2199', '3987', 'F', 'd', '8251', 'N', 'S']
Output (English): 14437