Input: Sentence: 'A baseball player breaks a baseball bat while hitting the ball'. Count the number of nouns in this sentence.
Output: 5