implementing error checking, validation, and hints