Input: Sentence: 'A polar bear diving off an outcrop of rocks into the water'. Count the number of nouns in this sentence.
Output: 4