ExamQuestions.com

Register
Login
Java SE 8 Programmer II Exam Questions

Oracle

Java SE 8 Programmer II

60 / 130

Question 60:

Given the code fragment: List<String> nL = Arrays.asList("Jim", "John", "Jeff"); Function<String, String> funVal = s -> "Hello : ".contact(s); nL.Stream() .map(funVal) .peek(System.out::print); What is the result? 

Answer options:

A. Hello : Jim Hello : John Hello : Jeff
B. Jim John Jeff
C. The program prints nothing.
D. A compilation error occurs.