We are interested in generating functions for the number of different ways to com
pose a bag of n donuts subject to various restrictions. For each of the restrictions
in below, find a closed form for the corresponding generating function.
1.The donuts must be chocolate, glazed, coconut, or plain and:
• there must be at least 3 chocolate donuts, and
• there must be at most 2 glazed, and
• there must be exactly 0 or 2 coconut, and
• there must be a multiple of 4 plain.
2. All the donuts are plain and their number is a multiple of 4