replace string between two regex python

Solutions on MaxInterview for replace string between two regex python by the best coders in the world

showing results for - "replace string between two regex python"
Sergio
30 Oct 2016
1a = r''' Example
2This is a very annoying string
3that takes up multiple lines
4and h@s a// kind{s} of stupid symbols in it
5ok String'''
6
7import re
8re.sub('\nThis.*?ok','',a, flags=re.DOTALL)
9' Example String'