A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2018-September/155364.html below:

[Python-Dev] Change in Python 3's "round" behavior

[Python-Dev] Change in Python 3's "round" behavior [Python-Dev] Change in Python 3's "round" behaviorGreg Ewing greg.ewing at canterbury.ac.nz
Sun Sep 30 18:04:31 EDT 2018
Steven D'Aprano wrote:
> (It's also called Dutch Rounding.)

Oh, so *that's* why Python does it! Fair enough. :-)

> Similarly for differences. If you perform many subtractions (let's say 
> you are paying off a loan, and calculating interest, then rounding to 
> the nearest cent) you have to care about bias.

If I'm paying off a loan, it's what the bank calculates that
matters, not what I calculate. And I hope the bank isn't
relying on the vagaries of Python floating point arithmetic
for its critical financial calculations.

-- 
Greg

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4