Task: Program Execution
Input (English): 10, 17, ['Q', 'H', 'J', '5403', 'f', 'f', '4489', 'w', '5491', 'F', '1843', 'm', '6997', '1609', '605', '1273', '8023']
Output (English): 20350