Computer Science
Which of the following keywords are not specific to exception handling?
- try
- except
- else
- finally
Python Exception Handling
1 Like
Answer
else
Reason — The 'else' keyword in Python is not specific to exception handling but rather plays a role in conditional statements and control flow structures. On the other hand, in exception handling constructs, the main keywords are 'try,' 'except,' and 'finally.
Answered By
2 Likes
Related Questions
The errors encountered when a user violates the syntax of a programming language while writing a code are termed as …………… .
- Compile time error
- Logical error
- Runtime error
- Exception
An interrupt or forced disruption that occurs when a program is run or executed is termed as …………… .
- Compile time error
- Exception
- Runtime error
- Logical error
Which block is a mandatory block in exception handling process?
- try
- except
- finally
- else
Forced exceptions are indicated using which of the following keywords?
- try
- except
- finally
- raise