def isDigit(word):
    """
    Test if a word is all digits.
    """
    ### keep only digits
    w = ''.join([l for l in word if l in '0123456789'])
    ### check if it is the same as it used to be
    return len(w) > 0 and word == w