Input: Sentence: 'two people riding horses jumping over obstacles'. Count the number of nouns in this sentence.
Output: 3