default value in __init__

David C. Ullrich dullrich at sprynet.com
Tue Oct 21 18:05:46 CEST 2008


In article 
<256f2adc-184c-4e18-993e-b8e031febcd0 at v72g2000hsv.googlegroups.com>,
 Paul McGuire <ptmcg at austin.rr.com> wrote:

> On Oct 14, 1:36 pm, "David C. Ullrich" <dullr... at sprynet.com> wrote:
> > >[...]
> 
> > In particular default parameters should work the way the user
> > expects! The fact that different users will expect different
> > things here is no excuse...
> >
> Are you being sarcastic? 

Why would you think that? Seems like a perfectly reasonable
request.

> Short of "import mindreading", I don't know
> how Python would know which behavior a given user would expect. 

I guess that's why I'm not a programmer - not able to think
this sort of thing through properly. Thanks. This explains
a lot of other things I've wondered about for years, like
why I need to tell the waitress whether I want tea or coffee,
why I sometimes need to switch channels on my TV... that's
always been what I like about c.l.py, getting answers to
questions I haven't even asked.

-- 
David C. Ullrich



More information about the Python-list mailing list