Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Verify Anagrams by PiotrStachowiak
def strtolist (x):
lista=[]
for i in x:
lista.append(i)
lista.sort()
if " " in lista:
lista.remove(" ")
return lista
def verify_anagrams(first_word, second_word):
first_word=first_word.lower()
second_word=second_word.lower()
first= strtolist(first_word)
second= strtolist(second_word)
if len(first)==len(second):
for i in range(0,len(first)):
if first[i]!=second[i]:
return False
else:
return False
return True
Nov. 21, 2016