Analysis of Insertion Sort and Merge Sort