A runtime error is a program error that occurs while the program is running. The term is often used in contrast to other types of program errors, such as syntaxerrors and compile time errors. There are many different types of runtime errors. One example is a logic error, which produces the wrong output.