Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
In [1]: l1 = [[[0]*3]*3]*3
In [2]: l1
Out[2]:
[[[0, 0, 0], [0, 0, 0], [0, 0, 0]],
[[0, 0, 0], [0, 0, 0], [0, 0, 0]],
[[0, 0, 0], [0, 0, 0], [0, 0, 0]]]
In [3]: l1[0][0][0] = 'x'
In [4]: l1
Out[5]:
[[['x', 0, 0], ['x', 0, 0], ['x', 0, 0]],
[['x', 0, 0], ['x', 0, 0], ['x', 0, 0]],
[['x', 0, 0], ['x', 0, 0], ['x', 0, 0]]]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.