Java entfernen Zahlen aus dem Set
public static void removeAllNumbersGreaterThan10(Set<Integer> set) {
Set<Integer> collectionOfTens = new HashSet<>();
set.stream().forEach(s -> {
if (s > 10) {
collectionOfTens.add(s);
}
});
set.removeAll(collectionOfTens);
}