Python re Module - Use Regular Expressions with Python - Regex Support
/*--- holy mAcar00ns!! --- */
The other option is to use the sub() function:
sub( replacement, string[, count = 0])
Returns the string obtained by replacing the leftmost non-overlapping occurrences of the RE in string by the replacement replacement. If the pattern isn't found, string is returned unchanged.
The optional argument count is the maximum number of pattern occurrences to be replaced; count must be a non-negative integer. The default value of 0 means to replace all occurrences.
all your bases ar--
ping moi pleeez
About this entry
You’re reading “
- 7:43 PM
pacman is coming
e belong to us!