Input: Sentence: 'A black and white photo of a broken bridge and horse carriages'. Count the number of nouns in this sentence.
Output: 4