-
Notifications
You must be signed in to change notification settings - Fork 3
Structs
Structs are a nice and tidy way to store data.
They can be declared by using struct 
In this example we declare a struct identified by a blue pixel 


Once a struct is declared, we can initialize it and store it into a variable by just passing the struct name as the value of the variable:
Now the variable 
0.
Fields in a struct variable can be accessed and updated by the use of the dot operator op.dot 
The following expression accesses the green field 
0, as previously said.
On the other hand, if you want to change a field's value, you can simply see the whole 'struct 


variable.set 
Here the green field 




