With a data class, you don’t need an init method to assign values to its attributes. However, sometimes you might want to use an init method to initialize certain attributes.
That is when dataclass’s __post_init__ comes in handy.
In the code above, I use __post_init__ to initialize the attribute info
using the attributes names
and ages
.