Need help with syntax on inheritance.
Peter Otten
__peter__ at web.de
Wed Oct 4 12:13:22 EDT 2006
SpreadTooThin wrote:
> the =() syntax indicates what?
No special syntax, just an empty tuple as a default parameter.
In this case I could have used an empty list, too, but I thought I'd spare
you the dangers of mutable default values as explained here:
http://www.python.org/doc/faq/general/#id53
> Just slightly off topic here but if Array had a bunch of initializers
> of its own, must all the 'optional' parameters be on the right.. ie the
> last parameters?
Yes.
Peter
More information about the Python-list
mailing list