Simple swap problem

I made a list with two items, each with an x and a y property. I try to swap the location of the two items in the list, but it doesn't work as expected. What's the problem? Here's the code:

put ((x:1, y:2), (x:3. y:4)) into list
put list
> outputs ((x:"1", y:"2"),(x:"3", y:"4")) as expected
put item 1 of list into temp
put item 2 of list into item 1 of list
put temp into item 2 of list
put list
> outputs ((x:"1", y:"2"), (x:"1", y:"2")) rather than ((x:"3", y:"4"), (x:"1", y:"2"))


  • SenseTalkDougSenseTalkDoug ForumAdmin admin
    It appears you've run into an odd bug. We'll look into getting it fixed right away. In the meantime, you can easily achieve what you want in this case with a single statement:
    put (item 2 of list, item 1 of list) into list
Sign In or Register to comment.