On Mon, Mar 23, 2020 at 3:53 AM Christopher Barker <python...@gmail.com> wrote:
>
> On Sun, Mar 22, 2020 at 2:08 AM Barry Scott <ba...@barrys-emacs.org> wrote:
>>
>> >>> Should `-+-+-+Spam'.stripprefix('-+')  remove just the first occurence?  
>> >>> All of them?  Does it need a 'count' parameter?
>> >> The only ways to use this function without counting is remove 1 prefix or 
>> >> remove all.
>
>
> I imagine that the count=1 is the most common use case for replace() anyway,
>

Do you mean "other than not specifying the count", or do you actually
mean that it's more common than replacing all? Because in my
experience, replacing all is *by far* the most common case - but yes,
replacing just one would be the next most common.

ChrisA
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/COFLPPUORH3IHXZAHUAV6ASQRTPW7CDU/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to