WA in GUESSIT problem

Hi,
I couldn’t find the bug in my solution for [Guess the Number] (CodeChef: Practical coding for everyone)

My solution: CodeChef: Practical coding for everyone

Thanks in advance