loicdescotte
2/19/2013 - 7:27 PM

Java 8 lamdba test

Java 8 lamdba test

import java.util.Arrays;

public class Lambda {
    public static void main (String[] args){
        Arrays.asList("aaa", "bbb", "ccc", "abb").stream()
        .filter((String w) -> w.startsWith("a"))
        .forEach(w -> System.out.println(w));
    }
}