0
Finally
When we use finally in exceptions?
4 Réponses
+ 3
Finally will run after the try and catch statements. it will execute regardless of whether there was an error or not. Use finally if you are, for instance, working with files and need to close the file stream. You could do this in finally because you want it to always be called, even if there is an error
0
Thank you! Do you know other examples when we use finally?
0
Basically anytime you need to clean something up.
0
Awesome, thanks!