Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for [old] Three Words by Moff
function isWord(w) {
for (let i = 0; i < w.length; i++) {
let n = w.charCodeAt(i);
if (n < 65 || (90 < n && n < 97) || n > 122)
return false;
}
return true;
}
function threeWords(data) {
let count = 0;
for (let w of data.split(' ')) {
if (isWord(w)) {
count += 1;
} else {
count = 0;
}
if (count == 3)
return true;
}
return false;
}
July 6, 2017