[docs] [issue29677] 'round()' accepts a negative integer for ndigits

Mark Dickinson report at bugs.python.org
Tue Feb 28 07:50:19 EST 2017


Mark Dickinson added the comment:

Yes, I think the initial description could be clarified. It currently reads:

> Return the floating point value number rounded to ndigits digits after the decimal point.

... which doesn't make it clear what happens for negative ndigits. 

There's a line in the second paragraph:

> values are rounded to the closest multiple of 10 to the power minus ndigits

which technically *does* cover the case of negative ndigits correctly, but I think it would be good to have a clarification in the first paragraph of the description.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue29677>
_______________________________________


More information about the docs mailing list