Hi,
this is my solution:
function findLongestWordLength(str) {
let arr = str.split(" ").sort(function(a, b){
return a.length < b.length
});
return arr[0].length;
}
findLongestWordLength("The quick brown fox jumped over the lazy dog");
Your solutions are very clever, @c0ka and @lionel-rowe
. I didn’t think about using .map() and Math.max .