code to srot arrays using quick, insertion, and merge sort