Exception Handling
- Authors: Krishna Kumar Mohbey1, Malika Acharya2
-
View Affiliations Hide Affiliations1 Department of Computer Science, Central University of Rajasthan, Rajasthan, India 2 Department of Computer Science, Central University of Rajasthan, Rajasthan, India
- Source: Basics of Python Programming: A Quick Guide for Beginners , pp 182-194
- Publication Date: December 2023
- Language: English
Exception Handling, Page 1 of 1
< Previous page | Next page > /docserver/preview/fulltext/9789815179637/chap8-1.gif
In this chapter, we introduce the concept of exception handling in Python. They are used to specify the alternate sequence of actions the program needs to jump to at the occurrence of the event. For example, if we want to print several pages from the printer and somewhere in the middle of the job the paper gets stuck in the printer. In such as situation we would want to jump to the function that aborts the printing and handles this situation by instant shut down of the printer. In such events comes the exception handling. When the program jumps to the exception handler part the current sequence of commands is abandoned and the commands given to the exception handler are executed. After the exception is tackled the programming returns to the point where the marker left. <br>
-
From This Site
/content/books/9789815179637.chap8dcterms_subject,pub_keyword-contentType:Journal -contentType:Figure -contentType:Table -contentType:SupplementaryData105