I'm a big fan of Python, but this example made me want to cry.

Grounds for first bullet:
>        value = reduce(lambda x,y: 0 < abs(x-y) <= len(nums) and y or
>        None, [int(item) for item in nums])

Grounds for second bullet:
>        print '%smatch' % (not value and 'Not a ' or '')

No speed improvement is sufficient to justify these abominable abuses of
syntax.  That's assuming that you're trying to do this to speed up your
code, and I'm not sure that it would.

I love Python, but I acknowledge that it's not for everyone--at least
not for people who feel the need to write code like this.

-- 
Andrew McNabb
http://www.mcnabbs.org/andrew/
PGP Fingerprint: 8A17 B57C 6879 1863 DE55  8012 AB4D 6098 8826 6868

Attachment: pgpMJ0ASnZ9E9.pgp
Description: PGP signature

/*
PLUG: http://plug.org, #utah on irc.freenode.net
Unsubscribe: http://plug.org/mailman/options/plug
Don't fear the penguin.
*/

Reply via email to