

def check_if_anagram(word1, word2):
    counter = Counter()
    for c in word1:
        counter[c] += 1
    for c in word2:
        counter[c] -= 1
    for values in counter.values():
        if (values != 0):
            return False
    return True

dataset/ETHPy150Open bt3gl/Python-and-Algorithms-and-Data-Structures/short_phone_interview_problems/check_anagram.py check_if_anagram/original