[New-bugs-announce] [issue43581] array assignment error

Wen Hao report at bugs.python.org
Sun Mar 21 10:45:47 EDT 2021


New submission from Wen Hao <haowenqi.zz at gmail.com>:

>>>mat = [[0]*4]*4
>>> mat
[[0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0], [0, 0, 0, 0]]
>>> mat[1][2]=1
>>> mat
[[0, 0, 1, 0], [0, 0, 1, 0], [0, 0, 1, 0], [0, 0, 1, 0]]

----------
components: Build
messages: 389230
nosy: haowenqi.zz
priority: normal
severity: normal
status: open
title: array assignment error
type: behavior
versions: Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue43581>
_______________________________________


More information about the New-bugs-announce mailing list