CodeHS - Intro to Python - Conditionals Quiz

Quiz
•
Computers
•
9th Grade - Professional Development
•
Hard
Thomas Archer
Used 99+ times
FREE Resource
15 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will print to the screen when the following program is run?
number = 5
greater_than_zero = number > 0
print(type(number))
5
True
<type ‘int’>
<type ‘bool’>
2.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will print to the screen when the following program is run?
number = 5
less_than_zero = number < 0
print(type(less_than_zero))
5
False
<type ‘int’>
<type ‘bool’>
3.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of this program?
number = 5
greater_than_zero = number > 0
if greater_than_zero:
print(number)
0
5
True
Nothing will print
4.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of this program?
number = 5
greater_than_zero = number > 0
if greater_than_zero:
if number > 5:
print(number)
0
5
True
Nothing will print
5.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of this program?
number = 5
less_than_zero = number < 0
if less_than_zero:
print(number)
number = number - 10
less_than_zero = number < 0
if less_than_zero:
print(number)
5
5
-5
5
-5
Nothing will print
6.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will be the output of this program?
number = 5
greater_than_zero = number > 0
less_than_zero = number < 0
if greater_than_zero:
print(number)
if less_than_zero:
print(number + 1)
if greater_than_zero and less_than_zero:
print(number + 2)
if greater_than_zero or less_than_zero:
print(number + 3)
5
5
7
5
7
8
5
8
7.
MULTIPLE CHOICE QUESTION
2 mins • 1 pt
What will the following program print when run?
above_16 = True
has_permit = True
passed_test = False
if above_16 and has_permit and passed_test:
print("Issue Driver's License")
elif above_16 or has_permit or passed_test:
print("Almost eligible for Driver's License")
else:
print("No requirements met.")
Issue Driver’s License
Almost eligible for Driver’s License
No requirements met
Nothing will print
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
Python Basics (CodeHS)

Quiz
•
7th - 12th Grade
16 questions
Python Unit 3 Codehs

Quiz
•
9th - 12th Grade
20 questions
TGT APCSA

Quiz
•
11th Grade
10 questions
Python Programming Essentials Quiz

Quiz
•
12th Grade
16 questions
3D Printing at NKN

Quiz
•
6th Grade - University
17 questions
Python Loops

Quiz
•
University
12 questions
Basic Python and Console Interaction - Mod3

Quiz
•
10th Grade
20 questions
Python SaNook

Quiz
•
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
30 questions
Introduction to Computers

Quiz
•
8th - 9th 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