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 -- https://mail.python.org/mailman/listinfo/python-list