Answered step by step
Verified Expert Solution
Question
1 Approved Answer
MCQ 1: MCQ 2: please answer When is else block executed in try, except, else scenario? Check all that applies. when there is no error
MCQ 1:
MCQ 2:
please answer
When is else block executed in try, except, else scenario? Check all that applies. when there is no error occurred in try block if the code does not enter into except block if the code enters in except block if there occurs any error in try block try: num1 = int(input('enter a number')) num2 int(input('enter another number ')) print (numlum2) except Exception: print('Some Exception', end='||') except ValueError: print('enter integer', end="11) except ZeroDivisionError: print('2nd number cannot be zero", end='11') except TypeError: print('number was not provided", end="||') O Some Exception|| O Some Exception|2nd number cannot be zero|| enter integer number was not provided 2nd number cannot be zero||Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started