fork download
  1. import re
  2.  
  3. pattern = r"\w\.\.\.(?=\w)"
  4. s = "hello...world"
  5. result = re.sub(pattern, r"\g<0> ", s,)
  6.  
  7. if result:
  8. print (result)
Success #stdin #stdout 0.03s 9780KB
stdin
Standard input is empty
stdout
hello... world