feat(isAnagram): desenvolviomento da função

This commit is contained in:
Lorena Camila Coelho Máximo 2022-11-02 14:29:26 -04:00
parent 60c42f4022
commit bb4c1d4133

View File

@ -1,4 +1,4 @@
export function isAnagram(word1, word2) {
// implementar logica aqui
return word1.length !== word2.length ? false : word1.toLowerCase().split('').sort().join('') === word2.toLowerCase().split('').sort().join('')
}