Alice and her little brother, Bob are playing a number guessing game.
Bob has selected a (hidden) integer $S$.
Alice can ask questions about the hidden number, which are of the following form: "Is the hidden number at least $x$?" Bob answers her questions with "Yes" or "No". Unfortunately, after $K ≥ 1$ questions, Bob gets bored of the game, and from then on, he will give false answers to all questions.
That is, Bob:
Note that Bob always answers correctly to the first question and Alice does not know the value of $K$.
Your task is to devise and implement a questioning strategy for Alice to identify the hidden number. Your score is based on the number of questions asked - the fewer questions, the better the score.