Message356648
I haven't used this bug reporting thing before so sorry if I mess something up.
Anyway i'm not sure exactly what is causing the issue but the issue appears when you have a for loop looping through an array and you make a variable and set it to that array and append something to it. If you do the same thing with numbers it works as expected but if you do it with an array it for some reason doesn't get reset every iteration. Run this and you'll see what i'm talking about.
Arr = [1,2,3,4,5]
for num in Arr:
Arr2 = Arr
Arr2.append(1) #the 1 can be anything
print(Arr2)
Also i'm interested to know why this happens, Thank You |
|
Date |
User |
Action |
Args |
2019-11-15 07:06:57 | Zach kuunka | set | recipients:
+ Zach kuunka |
2019-11-15 07:06:57 | Zach kuunka | set | messageid: <1573801617.55.0.5716631107.issue38808@roundup.psfhosted.org> |
2019-11-15 07:06:57 | Zach kuunka | link | issue38808 messages |
2019-11-15 07:06:57 | Zach kuunka | create | |
|