In this task, you need to count the number of nouns/verbs in the given sentence.

Example Input: Sentence: 'A man laughs while sitting on a bench'. Count the number of nouns in this sentence.
Example Output: 2

Example Input: Sentence: 'A man sitting in front of a computer taking a bit out of a pastry and holding a drink'. Count the number of nouns in this sentence.
Example Output: 6

Example Input: Sentence: 'A batter standing behind the catcher is taking a swing'. Count the number of nouns in this sentence.
Example Output:
3