Skip to content

Instantly share code, notes, and snippets.

@thoolihan
Created December 11, 2016 12:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save thoolihan/9c96cb17efc59b3ea16a031b55fb03da to your computer and use it in GitHub Desktop.
Save thoolihan/9c96cb17efc59b3ea16a031b55fb03da to your computer and use it in GitHub Desktop.
searching for quoted text
import re
p = re.compile('\"([^\"]+)\"')
str = 'I said "Hello There." She replied "hi"'
matches = p.findall(str)
for m in matches:
print('found: {0}'.format(m))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment