Add mergesort
Fix bug in quicksort