how to pass by reference??

Courageous jkraska at
Mon Feb 4 03:12:55 CET 2002

>Briefly, you don't.  Or you do.

All good stuff. But to answer directly, the best way to "pass
something by reference" is to have it be an attribute on an object,
and have what its being passed to a method. Those who adhere to
good OO design principles will quickly forget that Python doesn't
really have pass by reference. Or it doesn't. Or it does. :)


More information about the Python-list mailing list