The program lifecycle describes the phases source code of a program goes through from creation to execution.
Two key phases are:
- compile time — when source code is translated into an executable
- runtime — when the program is actively running
Docs:
Compile time is the phase when source code is translated into an executable before the program can run.
Errors detected during this phase (e.g., syntax errors, type mismatches) are called compile-time errors, as opposed to runtime errors that occur during execution.
Runtime is the phase when a program is actively executing. Errors that occur during this phase (e.g., dividing by zero, accessing a missing file) are called runtime errors.
The term is also used to mean a runtime environment — software that provides services a program needs while running.
For example, Node.js is a JavaScript runtime that executes JavaScript outside of a browser.
Shared libraries are loaded at runtime.