McqMate
Q. |
Which of the following blocks will be executed whether an exception is thrown or not? |
A. | except |
B. | else |
C. | finally |
D. | assert |
Answer» C. finally | |
Explanation: the statements in the finally block will always be executed, whether an exception is thrown or not. this clause is used to close the resources used in a code. |
View all MCQs in
Problem Solving and Python ProgrammingNo comments yet