We are asked to find the probability that it contains cookies given that it contains coffee.
This is called conditional probability and is given by

This means that the probability of event A given that event B has occurred.
For the given case, it becomes

The probability P(Cookies and Coffee) is the intersection of the column "Cookies" and the row "Coffee" divided by the grand total.

The probability P(Coffee) is the row total of the row "Coffee" divided by the grand total.

Finally, the conditional probability is

Therefore, the probability that it contains cookies given that it contains coffee is 0.25