when locking a pair of objects, the object with the lesser memory address is always locked first. the pair is unlocked in the opposite order.