Against PEP 240

Alex Martelli aleaxit at yahoo.com
Wed May 30 03:19:52 EDT 2001


"Robin Becker" <robin at jessikat.fsnet.co.uk> wrote in message
news:i2aJ6WAI3CF7Ew7I at jessikat.fsnet.co.uk...
    ...
> >And would that improve your quality of life noticeably when
> >compared to the I(1,2) notation for the same thing that you can
> >already use today...?
> ...
> the same argument applies exactly to rationals.

No it doesn't.  You're comparing (1,2)I versus I(1,2) -- ALL
that changes is the ordering of the SAME, IDENTICAL tokens.

Having 7.35 MEAN 7.35 rather than 7.3499999999999996 is
an issue of another conceptual order of magnitude, except to
people who have already been "brainwashed" by experience.

Having to write, e.g., 7.35r to mean 7.35, while unadorned
7.35 means 7.3499999999999996, is perverse, impossible
to justify to newcomers except by such handwaving as "the
computer being unable to deal with it" (utter hogwash, of
course, and newbies aren't stupid -- they see through such
cover-ups), and reminiscent of "hazing" in fraternities as
far as the appeal to "tradition" goes.

I'm not sure 7.35 should BE a _rational_, rather than a
decimal (a la Cowlishaw) -- rational might be most useful
to ME, but then, I should be among those experienced enough
to see some decoration needs as quite acceptable.  To a
newcomer, decimal might be preferable.  I'm quite willing
to listen to pro's and con's of each possibility (not that it
would do anybody much good -- _Guido_ has better be the
one listening:-), and have not made up my mind (the ABC
experience does suggest that rationals-by-default has some
serious pitfalls, if I understand that correctly).  But to have
unadorned 7.35 mean 7.3499999999999996 forevermore,
*THAT* is what I've come to see as unconscionable (after
just a few attempts teaching to newbies...).


Alex






More information about the Python-list mailing list