[Python-Dev] PEP239 (Rational Numbers) Reference Implementation and new issues

Andrew Koenig ark@research.att.com
02 Oct 2002 18:27:22 -0400


Eric> APL faced this problem twenty-five years ago.  I like its
Eric> solution; a `fuzz' variable defining the
Eric> close-enough-for-equality range.

I used to like APL's approach, but I've changed my mind.

Part of the reason is that there are some places where unfuzzed
comparison is essential, such as sorting.  Another part is that
fuzzy comparison destroys substitutability:  If a==b, it is
not always true that f(a)==f(b).

Much as I like APL, I'd rather use Scheme's numeric model.

-- 
Andrew Koenig, ark@research.att.com, http://www.research.att.com/info/ark