It will make selection words starting with "p" and ending with "a". So. Why it didnt work? :D Many sorry for stupid question.
function checkWord(word) {
if (word.charAt(0) = 'p' && word.charAt(word.length - 1) = 'a') {
return true;
} else {
return false;
}
Aucun commentaire:
Enregistrer un commentaire