
Python Syntax Quiz
Authored by Adham Elmuntser
Computers
1st Grade
Used 1+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct syntax for an if statement in Python?
if x = 5
if x == 5
if x := 5
if x != 5
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How do you check if two variables are equal in Python?
x == y
x = y
x != y
x < y
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? x = 5 if x > 3: print("Hello") else: print("Goodbye")
Hello
Goodbye
Error
None of the above
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which operator is used to combine multiple conditions in an if statement?
and
or
not
xor
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the value of x after the following code? x = 10 x += 5
10
15
5
20
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to check if a variable is in a list?
if x contains [1, 2, 3]
if x in [1, 2, 3]
if x includes [1, 2, 3]
if x has [1, 2, 3]
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? x = 7 y = 3 print(x % y)
2
3
1
0
Access all questions and much more by creating a free account
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
20 questions
الفاقد في البرمجة
Quiz
•
1st - 3rd Grade
20 questions
Powerpoint Av.1
Quiz
•
1st Grade
16 questions
Year 3 Baseline
Quiz
•
1st - 2nd Grade
20 questions
Computación 1ro y 2do básico
Quiz
•
1st Grade - University
20 questions
EVALUATION D'INITIATION AUX TICS /DABONE
Quiz
•
1st Grade
25 questions
ÔN TẬP TIN 8 GIỮA KÌ 2
Quiz
•
1st Grade
16 questions
Fundamentos de PowerPoint
Quiz
•
1st - 3rd Grade
15 questions
Adivina quien?
Quiz
•
1st - 10th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
Discover more resources for Computers
20 questions
Telling Time to the Hour and Half hour
Quiz
•
1st Grade
10 questions
Exploring Rosa Parks and Black History Month
Interactive video
•
1st - 5th Grade
20 questions
Place Value
Quiz
•
KG - 3rd Grade
13 questions
Fractions
Quiz
•
1st - 2nd Grade
20 questions
CVC Words
Quiz
•
KG - 1st Grade
15 questions
Place Value tens and ones
Quiz
•
1st Grade
16 questions
Money - Coins
Lesson
•
1st - 2nd Grade
20 questions
Halves and Fourths
Quiz
•
1st Grade