What is the result, if the file salesreport.dat does not exist?

Given the code fragment:

What is the result, if the file salesreport.dat does not exist?

Given the code fragment:

What is the result, if the file salesreport.dat does not exist?

A.
Compilation fails only at line 6

B.
Compilation fails only at line 13

C.
Compilation fails at line 6 and 13

D.
Class java.io.IOException

E.
Class java.io.FileNotFoundException

Explanation:

Compilation fails Line 13 : The resource br of a try-with-resources statement cannot be
assignedresources are final in try-with-resources statements



Leave a Reply 2

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


test

test

try-with-resources are final