a$:任意以a结尾的字符
方式1
regex=re.compile('[0-9]+')
res=re.findall(regex,'12321312321sddgfgf33223bbvcbv')
print(res)
方式2
mystr='12aaaafdfdsf4345345cccc'
re.sub('[0-9]+','',mystr)
a$:任意以a结尾的字符
方式1
regex=re.compile('[0-9]+')
res=re.findall(regex,'12321312321sddgfgf33223bbvcbv')
print(res)
方式2
mystr='12aaaafdfdsf4345345cccc'
re.sub('[0-9]+','',mystr)