implemented the guessing game