Input: Sentence: 'A man resting his hands on the back of a couch'. Count the number of nouns in this sentence.
Output: 4