General Motors (GM) Interview Question

How does a set ensure no duplicate objects?

Interview Answer

Anonymous

Mar 3, 2023

It uses its equals method to compare any new object to be added to other objects in the set.