[Tutor] RE: global vars vs. func args

Scott Widney SWidney@ci.las-vegas.nv.us
Tue, 12 Mar 2002 09:46:09 -0800


> > > """If you have a procedure with ten parameters, you 
> > > probably missed some."""
> > 
> > Is this sarcasm, or seriousness?  
> 
> Serious sarcasm.
> Most functions should have less than 10 params. If you have 
> one with 10 the likeliehood is you should rethink the design. 
> If you really, really do need 10 then the chances are that you 
> will need even more that you didn't realize at the time, 
> hence 'you probably missed some'.

An example of something that warrants myriad parameters is Tkinter; note,
though, that most arguments have default values.

Scott