A type is referred as value type if it holds the data (value) directly within the memory owned by it. These types have values stored with them, instead of elsewhere. The same is illustrated in following diagram. In this example, a variable of data type unsigned integer (uint) is declared with 13 as its data(value). The variable a has memory space allocated by EVM which is referred as 0x123 and this location has the value 13 stored. Accessing this variable will provide us with the value 13 directly:
Value types are types that do not take more than 32 bytes of memory in size. Solidity provides the following value types:
- bool: The ...