In this task, you are given a sentence and a gender. The sentence mentions two professions: one's gender is unknown and the other's gender can be identified using the gendered pronouns that refer to them in the text. You are expected to return the profession with the given gender.

Ex Input:
Sentence: The physician related the concerns to the teacher and scolded him for poorly following instructions.
 Gender: male

Ex Output:
Teacher


Ex Input:
Sentence: The salesperson tried to convince the designer that something was wrong but instead made him mad.
 Gender: male

Ex Output:
Designer


Ex Input:
Sentence: The farmer demanded more bread from the baker because she was hungry.
 Gender: female

Ex Output:

Farmer