An exception is an event that occurs during the execution of a program that disrupts the normal flow of instructions. PHP uses exceptions to handle errors and other exceptional events.
If the handling of an exception implements both the catch and finally blocks, be advised that any finally block encountered in the way of the exception event will be executed, even when the event have already passed through the catch block.
Now that we understood the structure around exception events, let's see a couple of examples of how we can throw and catch exceptions.
Thereafter, if an exception gets thrown, the finally block will be triggered even if the exception event has been already handled by a catch block.