update to insertion sort