Input: Sentence: 'An police officer riding on a police motorcycle'. Count the number of nouns in this sentence.
Output: 4