Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

second largest number in array javascript

['20','120','111','215','54','78'].sort(function(a, b) { return b - a; })[1];
// '120'
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #largest #number #array #javascript
ADD COMMENT
Topic
Name
7+4 =