Example 4 - Number guessing game

Let's play a little game! You think of a whole number from 1 to 100 inclusive, and I will try to guess the number by asking you some questions. I bet I can guess your number within 7 questions!