[issue38507] Improve the documentation of the nested list initialization

2019-10-17 Thread JUN-WEI SONG
JUN-WEI SONG added the comment: sorry that I did not notice it already documented -- resolution: -> duplicate stage: -> resolved status: open -> closed ___ Python tracker __

[issue38507] Improve the documentation of the nested list initialization

2019-10-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is already documented. See note 2 at https://docs.python.org/3/library/stdtypes.html#common-sequence-operations. -- nosy: +serhiy.storchaka ___ Python tracker

[issue38507] Improve the documentation of the nested list initialization

2019-10-17 Thread JUN-WEI SONG
New submission from JUN-WEI SONG : When I used the nested list, I need to initialize the nested list, so I used this expression: >>> nested_list = [[]] * 5 see also: https://stackoverflow.com/questions/12791501/python-initializing-a-list-of-lists So I later learned that such an expression w