Python Exception Handling

Quiz
•
Computers
•
10th - 12th Grade
•
Hard
Carol Luce
Used 90+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How many except statements can a try-except statement have?
None
One
Two
Multiple
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
When is the finally block executed?
when an exception occurs
when no exception occurs
never
always
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
When will the else part of try-except-else be executed?
always
when an exception occurs
when no exception occurs
never
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Can one except block handle multiple exceptions?
Yes
No
May be
Insufficient information
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The ZeroDivisionError may occur during which operation(s)?
Division
Modulus
Both
None
6.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Which of the following are reasons for exceptions to occur? (There is more than one answer!)
Entering invalid input
Doing wrong operation on specific data type
Wrong type arguments passed to built-in function
Incorrect assignment to variables
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the output of the attached python code?
Take the card out of ATM
Value Error Occurred
Done
Take the card out of ATM
Type Error Occurred
Take the card out of ATM
Some Error Occurred
Take the card out of ATM
Withdraw
Done
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
PCEP Section 4C: Python Built-In Exceptions Hierarchy

Quiz
•
12th Grade
10 questions
JS Practice: ITS Certification

Quiz
•
12th Grade
10 questions
Java Exception Handling Basics

Quiz
•
12th Grade
15 questions
G10 Q2 Review 2022

Quiz
•
10th - 11th Grade
11 questions
Python IF ELSE

Quiz
•
10th Grade
9 questions
Random in Python

Quiz
•
12th Grade
10 questions
4.6 Word Quizizz

Quiz
•
8th - 12th Grade
10 questions
7.9 Identifying and Correcting Errors Cambridge IGCSE 0478

Quiz
•
10th Grade - University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
10 questions
1.2 OSI & TCP IP Models Quiz

Quiz
•
10th Grade
20 questions
Digital Citizenship

Quiz
•
8th - 12th Grade
35 questions
Computer Baseline Examination 2025-26

Quiz
•
9th - 12th Grade
13 questions
Problem Solving Process

Quiz
•
9th - 12th Grade
20 questions
Hardware vs. Software Quiz

Quiz
•
7th - 10th Grade
10 questions
Understanding Algorithms with Pseudocode and Flowcharts

Interactive video
•
9th - 12th Grade
19 questions
AP CSP Unit 1 Review (code.org)

Quiz
•
10th - 12th Grade