Answer to March 24, 2003 Problem |
---|
Each year, I assign my programming classes the task of writing a program
to simulate the following guessing game. |
---|
Solution to Problem: The answer is 24 questions.
Why do 24 questions always suffice for this?
To locate a number between one and one billion requires only thirty questions, since is less than one.
|
1. Richard Johnson | La Jolla, California |
2. Keith Mealy | Cincinnati, Ohio |
3. Bill Funk | San Antonio, Texas |
4. James Alarie | University of Michigan -- Flint, Flint, Michigan |
5. Steve Muller | Winchester, Virginia |
6. Matt Stillwagon | Winchester, Virginia |
7. David & Judy Dixon | Bennettsville, South Carolina |
8. Tina Zahel | Winchester, Virginia |
9. Bob Hearn | Winchester, Virginia |
10. Walt Arrison | Philadelphia, Pennsylvania |
11. Jaime Garcia | Winchester, Virginia |
12. Jeff Gaither | Winchester, Virginia |