diff --git a/sortarray.js b/sortarray.js new file mode 100644 index 0000000..2b4e852 --- /dev/null +++ b/sortarray.js @@ -0,0 +1,11 @@ +var a=[1,3,2,7,4,10,9]; +for(var i=0;i0){ + a[i]=a[i+1]; + a[i+1]=a1; + } +} +console.log(a); \ No newline at end of file