[Tutor] KeyError: 'DEFAULT'
marc.tompkins at gmail.com
Fri Feb 20 06:05:41 CET 2009
On Thu, Feb 19, 2009 at 8:39 PM, Lie Ryan <lie.1296 at gmail.com> wrote:
> On Thu, 19 Feb 2009 11:45:52 -0800, Marc Tompkins wrote:
> > Don't use reserved words as variable names!
> str, set is built-in function not reserved words. Reserved words are like
> if, for, from, as (see the whole list type keywords in help() )
> Nevertheless, it is a bad idea to use built-in function names.
Furthermore, there _are_ cases when you want to use built-in type or
function names: when you're overloading them with your own versions. That's
why Python lets you use them in the first place... but if that wasn't what
you wanted to do, then avoid them like the plaque. (A little dental humor
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tutor