Created
March 3, 2023 10:54
-
-
Save jamesmorgan/62d4825dff0ed05009016c6cb369f77a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
contract Structs { | |
struct Shipment { | |
// Slot 1: 20 bytes packed with bool (1 byte) | |
address receiver; | |
bool delivered; | |
// Slot 2: uint 8 + uint128 = 1 slot | |
uint8 typeCode; | |
uint128 price; (Max size: 170141183460469231731687303715884105727) | |
// String min 1 slot | |
string package; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment