regex - How to replace pipe with regular expressions -
i have chain want replace occurrences given following pattern \d{1}[|], replace pipe space.
cll18|c municipio libre 4a secc|cll10|calle mpio. libre 4a secc|tknsprs|mpio. libre 4a secc.|cll20|mpio. libre
and stay follows:
cll18 c municipio libre 4a secc|cll10 calle mpio. libre 4a secc|tknsprs|mpio. libre 4a secc.|cll20 mpio. libre
is possible regular expressions??
(?<=\d)\| try this.re.sub(r"(?<=\d)\|"," ",test_string)see demo.
Comments
Post a Comment