We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Here is my one line Python solution! There are three candidates for the lowest cost, buying all of them at the normal price, buying all black presents and converting to white presents, or buying all white presents and converting to black presents. Then, we return the smallest of these prices.
Taum and B'day
You are viewing a single comment's thread. Return to all comments →
Here is my one line Python solution! There are three candidates for the lowest cost, buying all of them at the normal price, buying all black presents and converting to white presents, or buying all white presents and converting to black presents. Then, we return the smallest of these prices.