feat(isAnagram): Implementa função isAnagram
This commit is contained in:
parent
b2048f61d8
commit
2cf01bdc9f
@ -1,4 +1,4 @@
|
|||||||
export function isAnagram(word1, word2) {
|
export function isAnagram(word1, word2) {
|
||||||
// implementar logica aqui
|
// implementar logica aqui
|
||||||
|
return (word1.toLowerCase().split('').sort().join('')) === (word2.toLowerCase().split('').sort().join(''))
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user