Ikm Java 8 Test Updated [exclusive] Info

list.forEach(System.out::println);

CompletableFuture<Void> f = CompletableFuture.runAsync(() -> throw new RuntimeException(); ); f.exceptionally(ex -> System.out.println("caught"); return null; );

In the old days, Elias would have summoned a for-each loop. He would have built a temporary list, iterated, checked if conditions, and added elements one by one. It was effective, but it was procedural. It was "how" to do it, not "what" was being done.

list.forEach(System.out::println);

CompletableFuture<Void> f = CompletableFuture.runAsync(() -> throw new RuntimeException(); ); f.exceptionally(ex -> System.out.println("caught"); return null; );

In the old days, Elias would have summoned a for-each loop. He would have built a temporary list, iterated, checked if conditions, and added elements one by one. It was effective, but it was procedural. It was "how" to do it, not "what" was being done.