Tell us what’s happening:
Hello Guys,
Please i’ve tried this code logically and i know i should be correct… But…
Your code so far
function findLongestWordLength(sentence) {
let lWordLength = 0;
sentence = sentence.split(" ");
for (let i = 0; i < sentencelength; i++) {
if (sentence[i].length > lWordLength) {
lWordLength = sentence[i].length;
}
}
return lWordLength;
}
Your browser information:
User Agent is: Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/139.0.0.0 Mobile Safari/537.36 EdgA/139.0.0.0
Challenge Information:
Build a Longest Word Finder App - Build a Longest Word Finder App
https://www.freecodecamp.org/learn/full-stack-developer/lab-longest-word-in-a-string/build-a-longest-word-finder-app