In this exercise we are given the following snippet to find the longest word in the sentence.
findLongestWordLength(str) {
return maxLen
}
findLongestWordLength("The quick brown fox jumped over the lazy dog");
Below are our attempts
What is the correct answer? Attempt 2 as always, the reason being..
The split function
Top comments (0)