def gender(word, pos=NOUN):
w = word.lower()<EOL>if pos == NOUN:<EOL><INDENT>if w.endswith(gender_masculine):<EOL><INDENT>return MASCULINE<EOL><DEDENT>if w.endswith(gender_feminine):<EOL><INDENT>return FEMININE<EOL><DEDENT>if w.endswith(gender_neuter):<EOL><INDENT>return NEUTER<EOL><DEDENT>for g in gender_majority_vote:<EOL><INDENT>if w.endswith(gender_majority_vote[g]):<EOL><INDENT>return g<EOL><DEDENT><DEDENT><DEDENT>
Returns the gender (MALE, FEMALE or NEUTRAL) for nouns (majority vote).
        Returns None for words that are not nouns.