Session 11 : Exception Handling and Event Handling
![Gambar](https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEh_GUcT4EaB8LroCajQp2Js2wpOz1Dx2m3J17iuy0nSMpVSgcN2NKDvKJ_MKs5mVRyi9Pn6bdO0p56-IIjTXmyd2q-DiGjE58orEWJzafbeFucLhJZ2V0e-Z9i0bsb_8sgysP4lOMKW80Y/s640/Picture17.png)
Introduction to Exception Handling * In a language without exception handling When an exception occurs, control goes to the operating system, where a message is displayed and the program is terminated * In a language with exception handling Programs are allowed to trap some exceptions, thereby providing the possibility of fixing the problem and continuing so we can conclude that programmers need exception handling. Exception handling lets programs to trap some exceptions, thereby providing the possibility of fixing the problem and continuing. Basic Concepts * Many languages allow programs to trap input/output errors (including EOF) * An exception is any unusual event, either erroneous or not, detectable by either hardware or software, that may require special processing * The special processing that may be required after detection of an exception is called exception handling * The exception handling code unit is called an exception handler Exception Handling Alternatives ...