[Python-ideas] New explicit methods to trim strings

Jonathan Fine jfine2358 at gmail.com
Mon Mar 25 10:33:49 EDT 2019

Earlier, Anders wrote:
I propose naming them strip_prefix() and strip_suffix() and just skip the
one that does both sides since it makes no sense to me.

This is good, except I prefer subtract_prefix(a, b), truncate_suffix etc.
And for the two step process prefix_subtractor(a)(b) etc.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20190325/e92d9299/attachment.html>

More information about the Python-ideas mailing list