All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars
 perplexus dot info

 Guess a number (Posted on 2005-04-14)
If I think of a number between 1 and 1,000, guessing it in 10 yes-no questions is easy... so that's not the puzzle!

Guessing it in 10 yes-no questions, that must be all asked in advance, is also relatively easy... so that's not the puzzle either!

How many questions would you need to guess my number, if you had to ask all questions beforehand, and I also could lie once?

 See The Solution Submitted by Federico Kereki Rating: 4.3333 (12 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
 Beginning of a solution | Comment 10 of 19 |
If you ask 10 yes/no questions, there are exactly 1024 different possibilities for answers, and each of the 1000 numbers must correspond to a unique set of answers.

If up to one lie is allowed, the total number of possible sets of answers is still 2^N, where N is the number of questions.  However, the 1000 numbers must not only each correspond to a unique set of answers, but each pair must differ by more than two answers.

So there are at least a thousand possible sets of answers.  A thousand of them correspond to the numbers 1 to 1000, but none of these sets are two or less answers away from each other.  In a way, each number corresponds to N+1 sets of answers.  Therefore, at most, N questions can correspond to floor(2^N/(N+1)) numbers.  This sequence looks like this: 1, 1, 2, 3, 5, 9, 16, 28,...

In any case, it turns out that this is not the correct sequence, since with 4 questions, you can still only determine between 2 numbers.

Hmm... I'm stuck!  I shall now consult the other comments.

Edit:  I think it might be relevant to put a lower limit on the answer based on the above sequence.  Though the sequence is incorrect, the true sequence cannot be any higher than it.

The lower limit is 15, which can correspond to 2^14/15 = 16/15 * 1024 = 1092

Edit: Oops!  I said the lower limit is 15 when it is really 14.  The rest of the calculations are correct.

Edited on April 14, 2005, 11:34 pm

Edited on April 15, 2005, 10:22 pm
 Posted by Tristan on 2005-04-14 23:26:22

 Search: Search body:
Forums (0)