challenge-algorithms-v2.0-d.../08-isAnagram/index.js

6 lines
203 B
JavaScript
Raw Permalink Normal View History

export function isAnagram(word1, word2) {
// implementar logica aqui
if (word1.toLowerCase().split('').sort().join('')==word2.toLowerCase().split('').sort().join(''))
return true
return false
}