remove everything except alphanumeric characters from a string python regex code example
Example: python string strip non alphanumeric
Regular expressions to the rescue:
import re
stripped_string = re.sub(r'\W+', '', your_string)
Regular expressions to the rescue:
import re
stripped_string = re.sub(r'\W+', '', your_string)