Java examples for Lambda Stream:For Each
for Each item in List
//package com.java2s; import java.util.List; import java.util.function.Consumer; public class Main { public static <T> void forEach(List<T> list, Consumer<? super T> action) { for (T item : list) action.accept(item);// w ww. java2 s.c om } }