- 1 pill from jar 1
- 2 pills from jar 2
- 3 pills from jar 3
- 4 pills from jar 4
- 5 pills from jar 5

Your pharmacist gives you 5 jars filled with pills. The pills contained in each jar have an identical appearance and size (i.e. if you mixed all of the pills you wouldn't be able to tell them apart).

4 of the 5 jars hold pills that weigh 10 grams each, and the remaining jar holds pills that weigh 9 grams each. However, you don't know which jar is the one holding the lightweight pills. Keep in mind that all of the pills in all jars are identical in appearance and size.

You are given a weighing scale that can only be used **once**. Using this scale (only once), **how do you determine which jar is holding the 9 gram pills?**

*Note: assume the jars are quite large and that you have an unlimited quantity of pills from each jar.*

See solution.

Take a different number of pills from each jar and compare the expected mass with the observed mass. For example, take:

Expected mass (if all pills were 10 grams each) = (1+2+3+4+5) * 10 = 150 grams.

Suppose jar 4 contained the 9 gram pills. The total mass that you observe would be (1+2+3+5) * 10 + 4*9 = 146 grams. Since the mass you observe is 4 grams less than the expected 150 grams, you know jar 4 is holding the 9 gram pills.

In general (using the distribution of pills from above):

**Jar # = | Expected mass (150g) - observed mass |**

## Comments

Sign uporlog in with Facebookto comment.Curious3141A neater solution:

Label the jars 1 to 5. Take 9,8,7,6,5 pills from each jar respectively. The last (units) digit of the weight will indicate which jar it is.

Jay ElliottWoah, nice solution. Similar motivation to the solution I posted, but much cleaner once you work through it.

sincerekamalCan you explain me the solution in details ??

Jay ElliottThe solution is explained in detail under "Show Solution", but the key idea is that you take different amounts of pills from each jar so you'll know exactly which jar has the pills with a different weight.

For example, if jar 2 has the 9 gram pills and you picked 2 pills from jar 2, the total weight of the pills will be 2 grams less than the expected weight

Expected weight of pills coming from jar 2: 2 x 10g = 20g Actual weight of pills coming from jar 2: 2 x 9g = 18g

Ritesh Dwivediwhere are we using weighing scale?

Виктория ЯцковаTake from the first jar 1 pill, 2 from the second, 3 from the third one,... 5 from fifth If the weight is 149, then ( 150 - 149 ) = 1 then the first jar contains 9 gram pills If the weight is 148, then ( 150 - 148 ) = 2 then the second jar contains 9 gram pills .... 145 means that the 5th jar has light-weighted pills