newbe question about lists

Fredrik S fredrik.sjostedtNOfrSPAM at bemail.org.invalid
Sat Mar 4 19:52:41 EST 2000


Sorry for this simple question, but I can't go to sleep before I
have solved it.

I am running python on Beos for the first
time.

I'm going through a study course online, and ringt now I
am trying lists.

I type the following:
>>>
l1=["a1","a2","a3"]
>>> l2=["a4","a5","a6"]
>>> l3=l1
>>>
l3[1:1]=l2
>>> l3
['a1', 'a3', 'a4', 'a2']
>>> l1
['a1', 'a3',
'a4', 'a2']

QUESTION:
Why is value of l1 changed... The only
thing I can think of is B U G ...

Can anyone help me out...



* Sent from RemarQ http://www.remarq.com The Internet's Discussion Network *
The fastest and easiest way to search and participate in Usenet - Free!




More information about the Python-list mailing list