let arr = [4,3,54,6,23,1,3,5,9,4,3,1,10];
let n = arr.length - 1;
while (n > 0) {
for (var i = 0; i < n; i++) {
if (arr[i] > arr[i + 1]) {
let temp = arr[i];
arr[i] = arr[i + 1];
arr[i + 1] = temp;
}
};
n--;
}
alert(arr);