#include<iostream>
#include<string>
void insertSort(int *arr,unsigned int Length);
void insertSortMy(int *arr,unsigned int Length);
void insertSort(int *arr,unsigned int Length){
for(int iter=1; iter<Length; iter++){
int temp=arr[iter];
int i=iter-1;
while(i>=0&&arr[i]>temp){
arr[i+1]=arr[i];
--i;
}
arr[i+1]=temp;
}
}
void insertSortMy(int *arr,unsigned int Length){
for(int iter=1; iter<Length;iter++){
int temp=arr[iter];
int i;
for(i=iter-1; i>=0;--i){
if(arr[i]>temp){
arr[i+1]=arr[i];
}else{
break;
}
}
arr[i+1]=temp;
}
}