Input: Sentence: 'A motorcycle cop riding through a training course in the rain'. Count the number of nouns in this sentence.
Output: 5