Add binarySearch and swap operations