In article <[email protected]>, Peter Otten <[email protected]> wrote: >Aahz wrote: >> In article <[email protected]>, >> Peter Otten <[email protected]> wrote: >>> >>>Here's a trick to find the actual element. I think Raymond Hettinger >>>posted an implementation of this idea recently, but I can't find it at the >>>moment. >> >> Your code is inverted from Raymond's: > >I can't see the inversion.
You were wrapping the objects inserted into the set; Raymond's trick involved only wrapping the comparison object. It's therefore much more convenient. -- Aahz ([email protected]) <*> http://www.pythoncraft.com/ "If you think it's expensive to hire a professional to do the job, wait until you hire an amateur." --Red Adair -- http://mail.python.org/mailman/listinfo/python-list
