Why not 'foo = not f' instead of 'foo = (not f or 1) and 0'?
Jarek Zgoda
jzgoda at o2.usun.pl
Wed Jan 23 04:12:07 EST 2008
Gary Herron napisał(a):
> However there *is* a (subtle) difference between
> not f
> and
> (not f and 1) or 0
>
> The first produces a boolean value, and the second produces an int
> value, but since one is a subclass of the other, you'd have to write
> quite perverse code care about the difference.
Twisted sems to be perverted to the root.
--
Jarek Zgoda
Skype: jzgoda | GTalk: zgoda at jabber.aster.pl | voice: +48228430101
"We read Knuth so you don't have to." (Tim Peters)
More information about the Python-list
mailing list