fixed null input for arrays in insertion sort. stated merge sort