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

Home > Algorithms
Guess a number (Posted on 2005-04-14) Difficulty: 4 of 5
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.)
Some Thoughts Ideas | Comment 1 of 19

The easy puzzle is satisfied by expressing a number in binary and asking if the 1st, 2nd, ..., 10th binary digit is a 1.

There are 10 possible places where the clue giver might lie, and to find the answer, we must figure out which one it is.  To determine one of ten possibilities, you need 4 bits (yes-or-no answers), bringing the total to 14.  But now since there are 14 places which might be erroneous (or a lie) we have to be sure that we have enough to cover 14 possible places for the misinformation.  But indeed the extra 4 bits would be enough to cover in fact 16 possibilities.

So information-theoretically, 14 yes/no questions should suffice.

  Posted by Charlie on 2005-04-14 19:17:58
Please log in:
Remember me:
Sign up! | Forgot password

Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (3)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Copyright © 2002 - 2018 by Animus Pactum Consulting. All rights reserved. Privacy Information