Input: Sentence: 'A person swings their arms with a bat in hand'. Count the number of nouns in this sentence.
Output: 4