Skip to content

Instantly share code, notes, and snippets.

@Cyril-Pop
Created August 11, 2020 10:01
Show Gist options
  • Save Cyril-Pop/568d05a8d601f19cc635f7adf2b33fe6 to your computer and use it in GitHub Desktop.
Save Cyril-Pop/568d05a8d601f19cc635f7adf2b33fe6 to your computer and use it in GitHub Desktop.
specialSplit
import re
varstr = "Python c) like pip to install"
regEx = r'(\w\)\s\w+)\s?'
#mid = re.search(regEx, varstr).group(1)
newlst = re.split(regEx, varstr)
print newlst
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment