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.
Output: 6