0
s = "1234Bananas"
s = re.sub(r"\d", "", s)  

I know this will select the digits 1234, but what does the lowercase r stands for and do?

re.sub(**r**"\d", "", s)  
Willem Van Onsem
  • 443,496
  • 30
  • 428
  • 555
Mr Mystery Guest
  • 1,464
  • 1
  • 18
  • 47

0 Answers0