Please enable JavaScript to use CodeHS

CodeHS Glossary


Runtime error JavaScript

These errors are named runtime errors because they occur while a program is running. These types of errors don’t prevent a program from running.

For example, this program results in a crash:

function start(){
    while(frontIsClear()){
        move();
        move();
    }
}

All of the syntax in the program is valid, so the program is not prevented from running. The error occurs while the program is running, as Karel crashes into a wall.