Collect with toList() and toSet()
Elements from a Stream can be easily collected into a container by using the Stream.collect operation:
System.out.println(Arrays
.asList("apple", "banana", "pear", "kiwi", "orange")
.stream()
.filter...