def handle_words(str_word, dict_int_words): str_word = remove_punctuation(str_word) if str_word is not None: lower_case_word = str_word.lower() if lower_case_word not in CUSTOMIZED_STOPWORDS: dict_int_words[lower_case_word] += 1
def handle_hashtags(str_hashtag, dict_int_hashtags): str_hashtag = remove_punctuation(str_hashtag) if str_hashtag is not None: str_hashtag = "#" + str_hashtag.lower() dict_int_hashtags[str_hashtag] += 1