Validation and checking

Generates the secret number, checks that the guess is valid and if so
compares it against the secret number.