How did the new division ever get approved?! That's not pythonic! What if
you then need to divide two integers and find an element in a list or dict?
It will give you an error! I know that at the moment it is not implemented
unless imported from __future__, but I expect that it eventually might be.
That would be a problem with backwards compatibility.

On 2/27/07, Bjoern Schliessmann <
[EMAIL PROTECTED]> wrote:

[EMAIL PROTECTED] wrote:

> def compareValue(n1, n2):
>     i1 = int(n1)
>     i2 = int(n2)
>
>     dx = abs(i2 - i1)/min(i2, i1)
>     print dx
>     return dx < 0.05

You could also prepend

from __future__ import division

Regards,


Björn

--
BOFH excuse #237:

Plate voltage too low on demodulator tube

--
http://mail.python.org/mailman/listinfo/python-list

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to