This question already has an answer here:
- 1 Fake Coin among N Amount of coins 6 answers
The other day I was reading a puzzle book and found this classic: There are 9 coins on the table, but one of them is fake and weighs slightly less (or more, doesn't matter). How many measures do you have to make to be sure you know which coin is the fake one? This is not so hard, but the problem is the book forgot to mention there are nine coins, so I tried to solve it for an n number of coins (there is only one fake and n-1 real). I'm trying to find out an algorithm as simple as possible to find out the answer.