Could anyone help me to find an alternative way for this (if else statement)?
if(representatives.indexOf(word) == -1){
representatives.add(word);
}
else if(repeatWords.indexOf(word) == -1){
repeatWords.add(word); }
Aucun commentaire:
Enregistrer un commentaire