
Mastering Python Control Structures
Quiz
•
Information Technology (IT)
•
University
•
Practice Problem
•
Hard
Junel Ventura
Used 3+ times
FREE Resource
Enhance your content in a minute
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code: if 5 > 3: print('True') else: print('False')?
False
Maybe
Not Sure
True
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a correct syntax for an if statement in Python?
if (condition) do_something
if condition: do_something
if: condition do_something
if condition do_something;
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following code: x = 10; if x < 5: print('Low'); elif x < 15: print('Medium'); else: print('High')?
High
Low
Very High
Medium
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In Python, which operator is used for logical AND in conditions?
not
||
and
&&
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the result of the following expression: True and False?
True
False
Neither True nor False
False and True
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code: if 10 > 5: print('A'); if 10 < 5: print('B')?
C
A
B
D
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is an example of a chained if statement?
if (condition1) { // code } else { // code }
if (condition1) { // code }
if (condition1) { // code } else if (condition2) { // code } else { // code }
if (condition1) { // code } else if (condition2) { // code } else if (condition3) { // code }
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
Q6. Cybersecurity Best Practices
Quiz
•
University
20 questions
Entity Relationship Modeling Quiz
Quiz
•
University
15 questions
Use Cases and Domain Classes
Quiz
•
University
21 questions
Quiz tentang App Inventor
Quiz
•
11th Grade - University
15 questions
Data Literacy Quizizz
Quiz
•
6th Grade - University
15 questions
3.1(a)(b) - Lecture
Quiz
•
University
20 questions
2F-1 | Python Quiz | 14/10/2024
Quiz
•
University
15 questions
PPL 223 - (QUIZ 3) Data Types and Structures
Quiz
•
University
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
15 questions
4:3 Model Multiplication of Decimals by Whole Numbers
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
The Best Christmas Pageant Ever Chapters 1 & 2
Quiz
•
4th Grade
12 questions
Unit 4 Review Day
Quiz
•
3rd Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
Discover more resources for Information Technology (IT)
26 questions
Christmas Movie Trivia
Lesson
•
8th Grade - Professio...
7 questions
Different Types of Energy
Interactive video
•
4th Grade - University
20 questions
Slopes and Slope-Intercept Form
Quiz
•
8th Grade - University
7 questions
Force and Motion
Interactive video
•
4th Grade - University
7 questions
Biomolecules (Updated)
Interactive video
•
11th Grade - University
20 questions
Winter/Holiday Trivia
Quiz
•
KG - University
10 questions
WINTER WIN Time - ELA - 12/9/2025
Quiz
•
KG - University
7 questions
Human Impact on Resources
Interactive video
•
4th Grade - University
