Input: Sentence: 'some black animals are eating pumpkins in their pen'. Count the number of nouns in this sentence.
Output: 3