fork download
  1. import re
  2.  
  3. text = "15159970 (30.12.2015), 15615115 (01.01.1970), 11224455, 55441123 (28.11.2014 12:43:14)"
  4.  
  5. print( list(filter(None, re.findall(r'\([^()]+\)|(\d+)', text))) )
Success #stdin #stdout 0.02s 9452KB
stdin
Standard input is empty
stdout
['15159970', '15615115', '11224455', '55441123']