
Python Coding Quiz

Quiz
•
Computers
•
10th Grade
•
Medium
Jason Cross
Used 2+ times
FREE Resource
39 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct syntax to define a function in Python?
`def functionName:`
`def functionName():`
`function functionName():`
`function functionName:`
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a valid variable name in Python?
`2variable`
`variable-2`
`variable_2`
`variable 2`
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following code? ```python print(2 + 3 * 4) ```
`20`
`14`
`24`
`9`
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is used to create a comment in Python?
`// This is a comment`
`/* This is a comment */`
`# This is a comment`
``
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? ```python def add(a, b): return a + b print(add(2, 3)) ```
`2`
`3`
`5`
`None`
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a conditional statement in Python?
`for`
`while`
`if`
`def`
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the output of the following code? ```python x = 10 if x > 5: print("Greater") else: print("Smaller") ```
`Greater`
`Smaller`
`None`
`Error`
Create a free account and access millions of resources
Similar Resources on Wayground
40 questions
9th Grade - IT Programming - 2nd Cycle Exam

Quiz
•
9th Grade - University
44 questions
LATIHAN PYTHON

Quiz
•
10th Grade - University
39 questions
G12_End of Term2_Revision

Quiz
•
9th - 12th Grade
44 questions
Python

Quiz
•
10th Grade
40 questions
7.1.6 - 7.1.7 Sequence of Execution Quizizz Extra Practice (SD)

Quiz
•
10th Grade
41 questions
Final Day Quiz for ICT Skill Share

Quiz
•
4th Grade - Professio...
43 questions
Câu hỏi về Python

Quiz
•
10th Grade
40 questions
Логика 10 класс

Quiz
•
10th - 11th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

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

Interactive video
•
6th - 10th Grade
10 questions
Proper Keyboarding Techniques

Interactive video
•
6th - 10th Grade
10 questions
Understanding Computers: Hardware, Software, and Operating Systems

Interactive video
•
7th - 12th Grade
29 questions
AP CSP Unit 2 Review (Code.org)

Quiz
•
10th - 12th Grade