Home / Report Question

Q. Which method collects elements into a `Set`?
  • A. Collectors.toSet()
  • B. Collectors.toList()
  • C. Collectors.groupingBy()
  • D. Collectors.partitioningBy()