Making a number of checks on the user's input