Identify the FALSE statement made regarding Python Exceptions

Finally clause will always be executed irrespective of exceptions being raised or not

else clause will always be executed irrespective of exceptions being raised or not

There can be multiple except blocks for a single try block

Default except block always come at last

Verified Answer
Correct Option - b
Anush said

The FALSE statement regarding Python Exceptions is:

Option 2: else clause will always be executed irrespective of exceptions being raised or not.

The else clause is executed only when no exceptions are raised in the try block.

The other options are valid:

Option 1: Finally clause will always be executed irrespective of exceptions being raised or not. Option 3: There can be multiple except blocks for a single try block. Option 4: Default except block always comes at last.

Therefore, the correct option is: Option 2 else clause will always be executed irrespective of exceptions being raised or not.

To get all Infosys Certified Python Associate Exam questions Join Group https://bit.ly/infy_premium_group

We're passionate about offering best placement materials and courses!! A one stop place for Placement Materials. We daily post Offcampus updates and Placement Materials.

Qtr No. 213, New Town Yehlanka Indore 454775

admin@prepflix.in