Java Stream create from Array
import java.util.Arrays; import java.util.stream.Stream; public class Main { public static void main(String[] argv) throws Exception { Stream<String> names = Arrays.stream(new String[] { "CSS", "HTML", "SQL", "XML", "Java" }); names.forEach(System.out::println); }/*from w ww . j a v a 2 s. c om*/ }