Just now I was a little boring while working, so I started to try to write a quicksort, for the partition function it involved with the swap method.
I know it could be the simplest way by using an extra memory, also it could be amazingly solved by using XOR or Substraction.
But until now I just realized that the last two methods, although without the cost of extra memory, could be problem if you are swapping the same thing of the same address.
Just write here to remember, something you think you are familiar enough, answer is still not enough!!!
PS: the south park yesterday is kinda lame, I didn’t why they just put too much on Kenny. Also, I knew it, JB would be mocked!