Input: Sentence: 'A mammal appears to be hanging in a tree'. Count the number of nouns in this sentence.
Output: 2