Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python3
- import re
- s = "it ends-in-ing wow"
- match = re.search(r"[\s]+([\w\-]+)[\s]+", s)
- if match:
- print(match.group(1))
- else:
- print("Nothing found.")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement