You are asked to guess an integer between and inclusive.
Each time you make a guess, you are told either
(a) you are too high,
(b) you are too low, or
(c) you got it!
You are allowed to guess too high twice and too low twice, but if you have a guess that is too high or a guess that is too low, you are out.
What is the maximum for which you are guaranteed to accomplish this?
Clarification: For example, if you were allowed to guess too high once and too low once, you could guarantee to guess the right answer if , but not for . So, in this case, the answer would be .