### Question:
StreamUtils { static <T> Collector<T, ?, Set<T>> toLinkedHashSet() { return Collectors.toCollection(LinkedHashSet::new); } private  StreamUtils();   }### Answer:
@Test void testToLinkedHashSet() throws Exception { Set<String> result = Stream.of("a", "b", "c", "b") .collect(StreamUtils.toLinkedHashSet()); assertThat(result).containsExactly("a", "b", "c"); }