4 ms·
try..catch means you don't have to have perfect knowledge of what errors may be raised - which you simply do not have when dealing with external code. It also
by peterashford 8y ago
try..catch means you don't have to have perfect knowledge of what errors may be raised - which you simply do not have when dealing with external code. It also means that you can guarantee that no exceptional case has occurred that you have not handled. Either you explicitly deal with the issue or you have the option to fail & log.