I use a list in the argument of the following function:
def myFunct(myList):
print(myList) # display [0,1]
myModifiedList = list(myList)
myModifiedList[0]=-1
print(myList) # display [-1,1]
return myModifiedList
Of course, I'd like to display [0,1] at my second print in my function myList. I can't find out what's wrong here, I know that everything in python works by reference. However, my function array_copy should help me to avoid the problem I'm having.
Edit: I deleted the "weird" method, but still having the problem.