Task: Program Execution
Input (English): 5, 7, ['b', '5711', '2767', '5593', '6619', '7069', '4789', 'd', 'a']
Output (English): 18477