Snippets tagged “translate”
1 snippet uses this tag.
- Best way to strip punctuation from a stringPython
One way to strip punctuation from a string is to use the str.translate() method in combination with the string.punctuation constant.
1 snippet uses this tag.
One way to strip punctuation from a string is to use the str.translate() method in combination with the string.punctuation constant.