Efficient intersection of two List in Java?

You can use retainAll method:

columnsOld.retainAll (columnsNew);

Leave a Comment