Timeline for Unsort an array
Current License: CC BY-SA 4.0
10 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Dec 31, 2021 at 14:02 | comment | added | Fmbalbuena | Ok, thanks Richard. | |
Dec 31, 2021 at 14:02 | comment | added | Richard Neumann |
Same issue... Try it. a=[];b=a;print(a,b);a+=[1];print(a,b)
|
|
Dec 31, 2021 at 14:01 | comment | added | Fmbalbuena |
Ok, Or l=[];m=l ?
|
|
Dec 31, 2021 at 13:57 | comment | added | Richard Neumann |
No. This would make l and m the same list. And since the += operator modifies the list in-place, it would modify "both" lists: a=b=[];print(a,b);a+=[1];print(a,b)
|
|
Dec 31, 2021 at 13:52 | comment | added | Fmbalbuena |
l,m=[],[] can be l=m=[]
|
|
Dec 31, 2021 at 1:15 | history | edited | Richard Neumann | CC BY-SA 4.0 |
added 780 characters in body
|
Dec 31, 2021 at 0:59 | history | edited | Richard Neumann | CC BY-SA 4.0 |
deleted 5 characters in body
|
Dec 31, 2021 at 0:54 | history | edited | Richard Neumann | CC BY-SA 4.0 |
deleted 3 characters in body
|
Dec 31, 2021 at 0:49 | history | edited | Richard Neumann | CC BY-SA 4.0 |
deleted 6 characters in body
|
Dec 31, 2021 at 0:29 | history | answered | Richard Neumann | CC BY-SA 4.0 |