On Tue, Mar 20, 2007 at 09:03:43AM -0700, Dick Moores wrote:
.
.
.
> >Well, perhaps this is something for me to think about, but if you had asked
> >me to round 0.19945 to four decimal places, I would have told you the 
> >answer
> >is 0.1994, i.e., the same answer that Python gives.
> 
> Is this because that rounding conforms to "unbiased rounding"? If so, 
> then you won't like
> 
> >>> print round(0.19965, 4)
> 0.1997
> 
> (which rounds up to an odd number, 7)

Heh.  You're right.  I don't.  If I get some time, I'll try to dig
through the Python source code to see what they're doing.  Thanks.

                                        - Mike
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to