June 2018
Beginner
722 pages
18h 47m
English
As in the case of List, using type Set for the variable that holds a reference to the object of the class that implements the Set interface is a good programming practice called coding to an interface. It assures independence of the client code from any particular implementation. So, it is a good habit to write Set<Person> persons = new HashSet<>(), for example.
Read now
Unlock full access