wayground logo

Free Printable Worksheets

NEW

Font size

S
M
L
XL
Worksheets

Python Basics Quiz

Total questions: 20

Worksheet time: 10mins

Name
Class
Date
1.

What is Python primarily described as in the lesson?

a)

A compiled language used only for game development

b)

An interpreted language with readable syntax, important in web development, data science, and automation

c)

A hardware programming tool for robotics

d)

A markup language like HTML

2.

Why is Python considered beginner-friendly according to the lesson?

a)

It requires complex setup and compilation

b)

It has readable syntax and provides a strong foundation for logic and other languages

c)

It only supports advanced mathematical computations

d)

It is exclusively used for mobile app development

3.

Which of the following is an example of famous software mentioned in the lesson that uses Python?

a)

Microsoft Word

b)

Instagram backend

c)

Adobe Photoshop

d)

Google Chrome browser

4.

What does the print() function do in Python?

a)

It stores data in a variable

b)

It displays output to the screen

c)

It takes user input

d)

It performs arithmetic calculations

5.

What happens if you forget the parentheses in print("Hello, world!")?

a)

The program runs but prints nothing

b)

It causes a syntax error

c)

It prints the string without quotes

d)

It automatically adds the parentheses

6.

Why do we use indentation in Python, as per the exit ticket question?

a)

To make the code look pretty

b)

To define blocks of code, like in loops or functions

c)

To separate variables from operators

d)

To comment out lines of code

7.

What symbol is used for comments in Python?

a)

//

b)

/*

c)

#

d)

8.

In the independent practice on Day 1, what are students encouraged to experiment with in print statements?

a)

Complex loops

b)

\n for new lines and formatting

c)

Database connections

d)

File reading

9.

What is a variable in Python, using the analogy from the lesson?

a)

A mathematical equation

b)

A labeled box where you store a value

c)

A function that prints output

d)

A type of operator

10.

Which of the following is an example of declaring a string variable?

a)

age = 17

b)

height = 1.75

c)

name = "Ali"

d)

grade = A

11.

What data type is used for whole numbers in Python?

a)

float

b)

str

c)

int

d)

bool

12.

What would happen if you try to store a word in a variable meant for numbers without quotes?

a)

It automatically converts to a number

b)

It causes an error because strings need quotes

c)

It stores it as a float

d)

It prints the word directly

13.

How do you take user input in Python for an integer value?

a)

age = input("Enter your age: ")

b)

age = int(input("Enter your age: "))

c)

age = str(input("Enter your age: "))

d)

age = float(input("Enter your age: "))

14.

Which operator is used for floor division in Python?

a)

/

b)

%

c)

//

d)

*

15.

What does the % operator do?

a)

Addition

b)

Remainder (modulo)

c)

Multiplication

d)

Assignment

16.

In the guided practice on Day 2, what does the program ask the user to input?

a)

Their name and age

b)

Two numbers

c)

A single string

d)

A list of values

17.

What is the purpose of the assignment operator (=) in Python?

a)

To compare two values

b)

To store a value in a variable

c)

To perform subtraction

d)

To print output

18.

In the independent practice on Day 2, what task are students given?

a)

Print a hello world message

b)

Calculate and display the average

c)

Create a game

d)

Install a code editor

19.

According to the bell work on Day 1, what is the question asked?

a)

What is Python?

b)

In your own words, what is computer programming?

c)

Why learn variables?

d)

How to use operators?

20.

What is the main objective shared across both days in the lesson?

a)

Learn advanced Python libraries

b)

Describe basics of Python, write simple programs, declare variables, take input, and use operators

c)

Focus only on web development

d)

Install multiple code editors