Here to_yaml_properties limits the variables which will be saved when you call
YAML.dump to @num and @arr. The string variable, @str, will not be saved. If
you later on wish to reconstruct the objects based on the saved YAML data it is
your responsibility to ensure that any ‘missing’ variables are either not needed
(in which case they may be ignored) or, if they are needed, that they are initi alized with some meaningful value: