typekontroll
Typekontroll, or type checking, is the process of verifying and enforcing correct use of data types in programming languages. It aims to ensure that values are used in ways that conform to their declared or inferred types, preventing operations that would be semantically invalid, such as adding a number to a string.
Static type checking occurs at compile time. The compiler verifies types before the program runs, catching
Dynamic type checking happens at run time. Types are checked as the program executes, which provides flexibility
Many languages blend approaches in what is called gradual typing or hybrid type systems. These systems allow
Key concepts in type systems include type safety, structural versus nominal typing, and strong versus weak