Task: Program Execution
Input (English): 3, 7, ['4251', 'S', '5123', '3367', 'R', '2187', 's', '8051', '6059', '9061', 'F']
Output (English): s, 2187, R, 3367, 5123