import re


def __valid_word(word, stopword, language):
    """
    Check if the word is in the stopword list
    Return a boolean
    word = string
    stopword = stopword object (cf stopwords.py)
    language = string (french or english)
    """
    # print(word)
    # print(language)
    # print(word not in stopword.get_stopword()[language])
    # print(word not in stopword.get_ponctuation())
    # print(not re.match("\d+", word))
    # print(word not in stopword.get_stopword()[language]
    #         and word not in stopword.get_ponctuation()
    #         and not re.match("\d+", word))
    # print("-----------------------------------------")
    return (word not in stopword.get_stopword()[language]
            and word not in stopword.get_ponctuation()
            and not re.match("\d+", word))