fork(5) download
  1. import re
  2. rex = r"\s+(?=\d{2}(?:\d{2})?-\d{1,2}-\d{1,2}\b)"
  3. s = "2018-03-14 06:08:18, he went on 2018-03-15 06:08:18, lets play"
  4. print(re.split(rex, s))
  5.  
Success #stdin #stdout 0.04s 9836KB
stdin
Standard input is empty
stdout
['2018-03-14 06:08:18, he went on', '2018-03-15 06:08:18, lets play']