I have 2 lists:
one = [
[1, 2, 3, 4],
[2, 3, 4, 5],
[3, 4, 5, 6],
[4, 5, 6, 7]
]
two = [
[one[0][0], one[0][1], one[1][0], one[1][1]],
[one[0][2], one[0][3], one[1][2], one[1][3]],
[one[2][0], one[2][1], one[3][0], one[3][1]],
[one[2][2], one[2][3], one[3][2], one[3][3]]
]
When I input this one:
two[0][0] = 9
It comes out like this:
one: [[1, 2, 3, 4], [2, 3, 4, 5], [3, 4, 5, 6], [4, 5, 6, 7]]
two: [[9, 2, 2, 3], [3, 4, 4, 5], [3, 4, 4, 5], [5, 6, 6, 7]]
How can I get the same changes as in 'two' list in 'one' list when I changes the element in 'two' list, so that:
one: [[9, 2, 3, 4], [2, 3, 4, 5], [3, 4, 5, 6], [4, 5, 6, 7]]
two: [[9, 2, 2, 3], [3, 4, 4, 5], [3, 4, 4, 5], [5, 6, 6, 7]]