Author: Owain Clarke Date: To: Hampshire LUG Discussion List Subject: Re: [Hampshire] Python multiplicaton
On Thu, Jan 14, 2010 at 11:51:35AM +0000, Owain Clarke wrote: >> Could anyone explain to me why 3*7.6 gives me 22.799999999999997? I have
>> Python 2.5.2
>> OK, now I understand. Thanks all - will continue to seek a workaround,
and I'm guessing that, as the amounts are to do with pounds and pence, I
should convert everything pence before multiplying so that the
calculation is with integers.