#if you want to initialize a 9*9 two-dimensional array [([""]*9) for i in range(9)] #caution: the follow code can't work
[[""]*9]*9 shallow copies of list concatenated if you change one row then the prefix row will also be changed
2024-03-31 21:08:46
#if you want to initialize a 9*9 two-dimensional array [([""]*9) for i in range(9)] #caution: the follow code can't work
[[""]*9]*9 shallow copies of list concatenated if you change one row then the prefix row will also be changed