Task: Program Execution
Input (English): 8, 12, ['D', '5187', 'J', 'h', '6661', '6013', '333', '2771', 'x', 'z', 'B', '915']
Output (English): 3686