[Tutor] How to pass a large list to another object?

Kent Johnson kent37 at tds.net
Mon Feb 12 20:19:38 CET 2007

Hazlett, Les wrote:
> Hello,
> I just joined the list.  I have searched the archives unsuccessfully 
> trying to learn how to approach my problem.  So I have 2 questions -
>     1) How can I best pass a large list to another object? 

Just pass it. Python does not pass parameters by value. The list will 
not be copied, rather the object receiving the list will get a reference 
to the same value. (One consequence of this is that changes in the list 
via the new reference will be seen at the old reference; they both refer 
to the same list.)
>     2) How could I have found related discussion with a search of the
>     archives?

There is a searchable archive here:
but I'm not sure how you would have found an answer to this particular 

> Thanks for any help and advice on effectively using the tutor mailing list.

We're pretty friendly here. Just subscribe to the list and ask your 
questions. If you can show us some code that you have tried or that you 
are confused about, that helps a lot - make your best effort, then ask 
for help. If you get an error message that you don't understand, post 
the entire error, including the traceback, copied verbatim from the console.


More information about the Tutor mailing list