let sortArr = (arr1,arr2) =>{
let [i,j] = [0,0]
let newArr = []
while(i<arr1.length&& j < arr2.length) {
if (arr1[i]<arr2[j]) {
newArr.push(arr1[i])
i++
} else if (arr1[i]>arr2[j]) {
newArr.push(arr2[j])
j++
} else {
newArr.push(arr1[i])
newArr.push(arr2[j])
i++,j++
}
}
return newArr
}