basic sorting algos and randomized tests