Use list name as string

Vincent Davis vincent at
Wed Feb 4 20:36:17 EST 2009

if I start with
M = [1,3,5,7]
M is [1,3,5,7]
This seems one way, as [1,3,5,7] is not M in the sense that there is
no operation I can preform on [1,3,5,7] and get M back. Other than
asking/testing M==[1,3,5,7]
This seems fine to me. but when I savedata(M) it seems I should be
able to refer to both [1,3,5,7] and "M", "I mean I did just type it
why type it again)
My argument comes down to; we use M so we don't have to type
[1,3,5,7], I realize that this is in part because we might not no what
M will be.
This is starting to sound like double talk on my part, I have only
been programing in python for 2 weeks so my credibility is only that
of an outside that MAY have a reasonable way of thinking of this or at
least a feature I would like.

Thanks for the comments

by the way what is "**kwargs" I can't find any documentation on this?

Vincent Davis

On Wed, Feb 4, 2009 at 5:09 PM, Rhodri James
<rhodri at> wrote:
> On Wed, 04 Feb 2009 17:23:55 -0000, Vincent Davis <vincent at>
> wrote:
>> I guess what I am saying is that it does not seem like I am adding any
>> information that is not already there when I have to enter that list and
>> list name after all they are the same.
>> Thanks
> But you are.  Consider just for a moment what happens when you execute
> savedata([1, 2, 3, 55]).
> Fundamentally, the concept of a single unique name for any object isn't
> something built into the language (or, indeed, most languages I can think
> of).  An object can have no names (though it'll promptly get garbage
> collected if it isn't assigned to a name somehow), or just as easily
> one or many names.
> --
> Rhodri James *-* Wildebeeste Herder to the Masses
> --

More information about the Python-list mailing list