Insertion Sort(삽입정렬) #include void InsertSort(int arr[], int n){int i, j;int ins_data; for (i = 1; i = 0; j--){if (arr[j]>ins_data)arr[j + 1] = arr[j];elsebreak;} arr[j + 1] = ins_data;}}void main(){int arr[5] = { 5, 3, 2, 4, 1 };int i; InsertSort(arr, sizeof(arr) / sizeof(int)); for (i = 0; i < 5; i++)printf("%d ", arr[i]); printf("\n");}