Given n drinks, find optimum way to spend money if for each drink the price and the expiration date is given

Let’s say we are given $ n$ types of drinks, integer $ m$ representing the budget we have and integer $ d$ representing the cost of delivery when we order some drinks. For each of the $ n$ drinks we are given $ P_i \text{ the price of i-th drink and } E_i – \text{expire date}$ . For example $ (3, 2)$ is representing drink with price $ 3$ for one bottle and the second number means that this drink can be used at most $ 2$ days after we buy it.

We can order as many drinks as we want from each type, but each time we order we are paying $ d$ dollars for delivery. Notice that the delivery doesn’t matter in the day, so we can buy drink with exprite date $ 2$ and used it either today, tomorrow, or the day after tomorrow.

I think that this problem can be solved with greedy strategy, but I’m not able to find anything that can lead to correct result and good time complexity.

Here are some things that I got so far:

We don’t want to buy things that will be expired, so from each drink with price $ P_i$ we will spend at most $ P_i \cdot(E_i + 1)$

Because we may have big budget, it is good to find one way of buying drinks and use it couple times, until we don’t run out of money from the budget.

We will first buy the cheaper drinks and for the more expensive ones we should decide should we make a new order, or buy some drinks from the next type.

I didn’t got anything that lead to correct strategy, so please share some of your ideas.

Which Animal won’t Drink water in its Lifetime?

I have wondered whether any animal can last the longest without water. So I Googled and found that there is an animal called Koala, which don't require water in its lifetime. It quenches its thirst by feeding on eucalyptus leaves, which contains more moisture. Eucalyptus leaves is the fifty percent of the feed for this animal…

See the picture of KOALA below……

Which Animal won't Drink water in its Lifetime?

Can I prove my legal age *implicitly* so that I can drink in the UK?

I hold Swede passport and I am traveling to UK this month. I’ve read ( that legal age of drinking alcohol in UK is 16 to 18 depending on the type of beverage.

I am an undergraduate student and look about 18. Can I use my my university card (Swede uni) in place of my passport in bar entries. Since a typical university student is 18 or above so can my university card be as a proof of age, implicitly though?

How to I prove my legal age so that I can drink in New Zealand?

I am traveling to New Zealand in the spring, and I have a question regarding alcohol consumption. The legal drinking age in the United States is 21, yet it is 18 in New Zealand. I am over the age of 18 so I plan on drinking. However, I am assuming my American ID is not going to work to prove my age, so will I use my passport? Asking any students who have studied abroad or just anyone who knows!