Which two modifications enable the code to print Open Close?

Given:


Which two modifications enable the code to print Open Close?
A. Replace line n1 with:
class Folder implements AutoCloseable {
B. Replace line n1 with:
class Folder extends Closeable {
C. Replace line n1 with:
class Folder extends Exception {
D. At line n2, insert:
final void close () {
System.out.print(“Close”);
}
E. At line n2, insert:
public void close () throws IOException {
System.out.print(“Close”);
}

Download Printable PDF. VALID exam to help you PASS.

5 thoughts on “Which two modifications enable the code to print Open Close?

Leave a Reply

Your email address will not be published. Required fields are marked *


The reCAPTCHA verification period has expired. Please reload the page.