Abe
0
Q:

replacing a value in string using aregular expression pyhton

import re
s = "Example String"
replaced = re.sub('[ES]', 'a', s)
print replaced 
3

New to Communities?

Join the community