In the try-with-resources statement, if an exception is thrown, what happens to the resources declared within the try?
They must be manually closed in the catch block.
The program terminates without closing them.
They are automatically closed.
They remain open.