On Jan 4, 2008 8:58 AM, <[EMAIL PROTECTED]> wrote: > > Guido> Looks like in Python 2.6, round(0.5) right now returns 0.0, > Guido> whereas in 2.5, it returns 1.0. > > Guido> I think it should return 1.0, for best compatibility with Python > Guido> 2.5. > > And for best compatibility with everything else! <0.5 wink>
Should I round that to 0 whole winks or 1 whole wink? Rounding 0.5 to 0 is a new fad, called round-to-even, or statistician's rounding. Read http://en.wikipedia.org/wiki/Rounding . It's a standard, and more correct when doing statistical calculations. That's why we've chosen it for Python 3.0. But it should not bleed into Python 2.6. -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com