Input: Sentence: 'A bench next to a wall with a staircase behind it'. Count the number of nouns in this sentence.
Output: 3