[EMAIL PROTECTED] wrote: > On Feb 15, 11:50 pm, Steve Holden <[EMAIL PROTECTED]> wrote: >> Dan Bishop wrote: >>> On Feb 15, 10:24 am, nexes <[EMAIL PROTECTED]> wrote: [...] >>>> What are everyone else's thoughts on this? >>> days_in_month = lambda m: m - 2 and 30 + bool(1 << m & 5546) or 28 >> Elegant, but the 5546 is way too magical for readability. > >>>> int( '0101010110101'[::-1], 2 ) > 5546
Yes, I'm aware of that. Adding it as a comment might help. regards Steve -- Steve Holden +1 571 484 6266 +1 800 494 3119 Holden Web LLC http://www.holdenweb.com/ -- http://mail.python.org/mailman/listinfo/python-list