On Fri, May 27, 2011 at 1:52 PM, Steven D'Aprano <steve+comp.lang.pyt...@pearwood.info> wrote: > Because "lst" is not a real word. To native readers of languages derived > from Latin or Germany, such as English, it is quite a strange "word" > because it has no vowel. In addition, it looks like 1st (first).
Contrived examples are always awkward; in real examples, there's often an alternative based on the list's purpose, which can then be used to offer a name. > Sometimes shadowing is harmless, and sometimes it's useful. Agreed on both those halves; and obviously, the times where it's useful are very much important. I have to say, I do like Python's lack of keywords for these things; the ability to shadow is a flexibility that means that, for the most part, new builtins can be added to the language without breaking existing code. ChrisA -- http://mail.python.org/mailman/listinfo/python-list