Boolean idioms (was Re: re Challenge: More Compact?)
Aahz Maruch
aahz at panix.com
Mon Jul 16 09:33:00 EDT 2001
In article <mailman.995247446.16415.python-list at python.org>,
Tim Peters <tim.one at home.com> wrote:
>
>Well, it's un-Pythonic to try to emulate Perl undef via Python None; it's
>idiomatic to return 0 for false and 1 for true, [...]
I know that it's a frequent Python idiom to use 0/1, but where is it
specifically un-Pythonic to use None/1?
--
--- Aahz <*> (Copyright 2001 by aahz at pobox.com)
Hugs and backrubs -- I break Rule 6 http://www.rahul.net/aahz/
Androgynous poly kinky vanilla queer het Pythonista
"How come we choose from just two people for President but more than 50
for Miss America?" --AEN
More information about the Python-list
mailing list