1Z0-809 Web TestEngine demo

Exit VCEDump 1Z0-809 Java SE 8 Programmer II
Question 8 of 32
0% complete
Q8 Single choice

Given the code fragment:

public static void main (String[] args) throws IOException {
BufferedReader brCopy = null;
try (BufferedReader br = new BufferedReader (new FileReader("employee.txt"))) { //
line n1
br.lines().forEach(c -> System.out.println(c));
brCopy = br; //line n2
}
brCopy.ready(); //line n3;
}

Assume that the ready method of the BufferedReader, when called on a closed BufferedReader, throws an exception, and employee.txt is accessible and contains valid text.

What is the result?

Sign in to mark questions

Sign in to save marked questions and return to this demo.

Sign in