Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript sort array smallest to largest

var numArray = [140000, 104, 99];
numArray.sort(function(a, b) {
  return a - b;
});

console.log(numArray);
 
PREVIOUS NEXT
Tagged: #javascript #sort #array #smallest #largest
ADD COMMENT
Topic
Name
8+8 =