H
Helmut Jarausch
Hi,
I must be blind but I don't see what's going wrong
with
G=[[]]*2
G[0].append('A')
G[1].append('B')
print G[0]
gives
['A', 'B']
as well as
print G[1]
I was expecting
['A']
and
['B']
respectively.
Many thanks for enlightening me,
Helmut.
--
Helmut Jarausch
Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany
I must be blind but I don't see what's going wrong
with
G=[[]]*2
G[0].append('A')
G[1].append('B')
print G[0]
gives
['A', 'B']
as well as
print G[1]
I was expecting
['A']
and
['B']
respectively.
Many thanks for enlightening me,
Helmut.
--
Helmut Jarausch
Lehrstuhl fuer Numerische Mathematik
RWTH - Aachen University
D 52056 Aachen, Germany