Input: Sentence: 'A baby laying next to a teddy bear on a blanket'. Count the number of nouns in this sentence.
Output: 4