Input: Sentence: 'a man in a green shirt is playing tennis'. Count the number of nouns in this sentence.
Output: 3