SyntaxFix
Write A Post
Hire A Developer
Questions
Let's not forget our relatively new friend, java-8 stream API. If you need to preprocess list before converting it to a set, it's better to have something like:
list.stream().<here goes some preprocessing>.collect(Collectors.toSet());