Compare the number of comparisons used by the insertion sort and the binary insertion sort to sort the list 7, 4, 3, 8, 1, 5, 4, 2.

Solution:Step1Given thatThe list 7, 4, 3, 8, 1, 5, 4, 2.Step2To find We have to compare the number of comparisons which is used by the insertion sort and the binary insertion sort to sort the given list .Step3Insertion sort is a basic sorting algorithm that assembles the final sorted array one item at a time.Binary insertion sort is a variation of Insertion sorting in which appropriate location to insert the selected element is found using the binary search.Step4We have The list 7, 4, 3, 8, 1, 5, 4, 2.Sorting using insertion sortCompare the first two element 7 and 4 means 7>44, 7, 3, 8, 1, 5, 4, 2.Again compare third element with first element means 3 and 44>3 then3,4, 7, 8, 1, 5, 4, 2.Again compare fourth element to all three sorted element means 8 with 3,4,78>3, 8>4,8>7 then3,4, 7, 8, 1, 5, 4, 2.Again compare fifth element with first element means 1 with 33>1 then1,3,4, 7, 8, 5, 4, 2.Again compare 5 with 1,3,4,71<5, 3<5,4<5,7>5 then1,3,4,5, 7, 8, 4, 2.Again compare 4 with 1,3,41<4,3<4,4=4 then1,3,4,4,5, 7, 8, 2.Finally...