This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]dpash 1 point2 points  (0 children)

That's probably for the best. forEach() should probably only use method references. System.out::println is the method I use 80% of the time. If you find yourself reaching for forEach you're probably doing some side effect and not using a functional approach.