> I imagine that the count=1 is the most common use case for replace() anyway,
>
Do you mean "other than not specifying the count",
yes, that -- most common use case for using count at all.
I'm suggesting that if -1 and 1 were the only options, very few people would notice :-)
Because in my
experience, replacing all is *by far* the most common case
Agreed -- that's why it's a good default. I don't know that I ever even noticed that count was there before now :-)
-CHB
--
Christopher Barker, PhD
Python Language Consulting
- Teaching
- Scientific Software Development
- Desktop GUI and Web Development
- wxPython, numpy, scipy, Cython