fix quick sort
add sampling count