made the valueError in the 'else' in main a little nicer