fork download
  1. import re
  2. array= ['AB.01.001 Hello','BA.10.004','CD.10.015 Good bye']
  3. regex = re.compile(r'[A-Z]{2,3}\.[0-9]{2}\.[0-9]{3}\s*')
  4. filtered = filter(None, map(lambda i: regex.sub('', i), array))
  5. print(list(filtered))
Success #stdin #stdout 0.02s 27712KB
stdin
Standard input is empty
stdout
['Hello', 'Good bye']