The generalization is based on the concept of templates in C ++, if you are familiar with them.
Its a way to implement an algorithm or data structure, but delays the actual type in which it is used.
Then the list can be assigned by any type of your choice: int, string, and even custom types, which is assigned to the type when building the list. But you can use add remove list operations, etc.
You can really save a lot of coding effort by getting used to generics. And you do not need to insert and unpack between types.
Java also has generics. They are called wildcards.
bovium
source share