Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

find smallest length string in an array js

var arr = ['cats', 'giants', 'daughters', 'ice'];
var min = Math.min(...arr.map(({ length }) => length));
console.log(min);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #find #smallest #length #string #array #js
ADD COMMENT
Topic
Name
4+5 =