[Python-ideas] Why does `sum` use a default for the`start`parameter?

Raymond Hettinger python at rcn.com
Sun Dec 6 02:18:38 CET 2009


["Terry Reedy"]
> FWIW, sum was designed for summing numbers at C speed. I think it 
> probably is as good a compromise as we can get. It is easy to program 
> any other exact behavior one wants, and summing user objects is going to 
> go at Python speed anyway. Certainly, none of the suggested alterations 
> strike me as worth breaking code.

Wisely spoken.


Raymond




More information about the Python-ideas mailing list