Commit c4c421d6 authored by Pablo Galindo's avatar Pablo Galindo Committed by GitHub

bpo-37134: Use PEP570 syntax for sum() (GH-13851)

parent e9858042
......@@ -1562,11 +1562,11 @@ are always available. They are listed here in alphabetical order.
about strings, see :ref:`textseq`.
.. function:: sum(iterable[, start])
.. function:: sum(iterable, /, start=0)
Sums *start* and the items of an *iterable* from left to right and returns the
total. *start* defaults to ``0``. The *iterable*'s items are normally numbers,
and the start value is not allowed to be a string.
total. The *iterable*'s items are normally numbers, and the start value is not
allowed to be a string.
For some use cases, there are good alternatives to :func:`sum`.
The preferred, fast way to concatenate a sequence of strings is by calling
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment