A curious bit of code...

forman.simon at gmail.com forman.simon at gmail.com
Fri Feb 14 03:45:16 CET 2014


For the record I wasn't worried about the performance.  ;-)

It was for Tkinter event strings not markup tags.

I'm glad this was the time winner!

"key and key[0] == '<' and key[-1] == '>'"


Cheers to the folks who did the timings (and saved me from the trouble!)

Last but not least...  s[::len(s)-1]   omg!!?   ;-D



More information about the Python-list mailing list