Moved swap. Implemented median-of-three method.