Task: Program Execution
Input (English): 3, 5, ['g', 's', '1247', '5935', 'A', '2299', 't', '8403', 't', 'D', 'S', 'I', '3757', 'S', '4349', 'D', 'i']
Output (English): 1247, 8403, 3757