Input: Sentence: 'Two elephants in a grassy field with trees in the background'. Count the number of nouns in this sentence.
Output: 4