Written by the Fiveable Content Team โข Last updated September 2025
Verified for the 2026 exam
Verified for the 2026 examโขWritten by the Fiveable Content Team โข Last updated September 2025
Definition
Static typing is a programming language feature that requires variables to be declared with their data types before they can be used. It helps catch errors at compile-time by enforcing type compatibility.
Related terms
Dynamic Typing: In contrast to static typing, dynamic typing allows variables to hold values of different types during runtime.
Type Inference: Type inference is a feature in some programming languages where the compiler automatically determines the data type of a variable based on its assigned value.
Strong Typing: Strong typing refers to a programming language's ability to prevent operations between incompatible data types, ensuring type safety.