It can be actually done in much fewer measurements by dividing the pile in thirds. This way even in the worst scenario you reduce the number of coins by the biggest possible amount in every step.

Imagine 100 coins. Divide it into piles of 33, 33, 34 and measure the equal ones. This way you end up with at most 34 for the next step as opposed to 50 if you were to divide the pile only in half.

## re: Daily Challenge #108 - Find the Counterfeit Coin VIEW POST

TOP OF THREAD FULL DISCUSSIONIt can be actually done in much fewer measurements by dividing the pile in thirds. This way even in the worst scenario you reduce the number of coins by the biggest possible amount in every step.

Imagine 100 coins. Divide it into piles of 33, 33, 34 and measure the equal ones. This way you end up with at most 34 for the next step as opposed to 50 if you were to divide the pile only in half.

The original problem that I heard was with 9 coins given 1 counterfeit, to find it with 2 measurements.

Good one! This changes it to the following code:

which is equal to