August 2019
Intermediate to advanced
486 pages
13h 52m
English
Complex types such as string and bytes, which do not always fit into 256 bits in a variable, have to be handled more carefully than the other value types. Copying reference types is quite expensive and the developer can specify where these reference types should be stored. As shown in the following example, string is stored in memory temporarily:
string memory param1 = "Hello World !";
Similarly, the storage keyword can be used to store the variable data in Ethereum storage.