What are the types of errors that can be encountered in programs?