On Sun, Aug 31, 2014 at 6:37 PM, Steven D'Aprano <steve+comp.lang.pyt...@pearwood.info> wrote: > - Use print() to see the intermediate results: > > a = e[0].isupper > print(e[0], a, a == False, a == True)
And I'll add to this: *Copy and paste* the original code to craft this output statement. I recently was trying to figure out a problem, and retyped to create the output statements... and I didn't make the same typo, so it worked fine. For some reason, my eye didn't notice the error, and I couldn't understand why the intermediate results were correct and the overall result was wrong. (And no, it wasn't the kind of 'wrong' that results in a nice tidy exception. It just resulted in wrong results.) ChrisA -- https://mail.python.org/mailman/listinfo/python-list