def detectCapitalUse(word):
        return (word.isupper() or
                word.islower() or
                (word[0].isupper() and word[1:].islower()))

142d3dbd32053c022d5ac625115de0158324fda3
<mask token>

def detectCapitalUse(word):
    return word.isupper() or word.islower() or word[0].isupper() and word[1:
        ].islower()

def detectCapitalUse(word):
        return (word.isupper() or
                word.islower() or
                (word[0].isupper() and word[1:].islower()))
