FileInputStream in try block, what do we write in finally block (Core Java Interview Question #529)

preview_player
Показать описание
In this session, I have explained and practically demonstrated in Java, FileInputStream code when written in try block, then we need to write code to close the object of FileInputStream to stop its memory leak in finally block. Whether the try block or catch block executes or not, finally block will get executed at any cost.

If FileInputStream statements is written in try block, what are the statements we write in finally block (Core Java Interview Question #529)

Рекомендации по теме
join shbcf.ru