Data Type - Static Typing

1 - About

Static typing, otherwise known as type enforcement, is when a variable got a type that will never changes during runtime.

The variable (container) is declared to hold only a specific type of value, such as number or string.

Static typing is typically cited as a benefit for program correctness by preventing unintended value conversions.

This kind of language are called typesafe

The counterpart of static typing is Weak typing that allows a variable to hold any type of value at any time.

3 - Example

  • Java
  • C
  • Typescript
code/type/static_typing.txt · Last modified: 2017/09/17 17:36 by gerardnico