Task: Program Execution
Input (English): 2, 5, ['W', '5035', 'B', 'b', '3965', '2949', '1843', 'k', '3289', '6315', 'k', 'w', '341', '473', '6125']
Output (English): 5035, B, b, 3965