Python 2

Python 2

9th Grade

23 Qs

quiz-placeholder

Similar activities

Python Basics

Python Basics

7th - 9th Grade

23 Qs

Introduction to Python

Introduction to Python

University

20 Qs

Data Types- Python

Data Types- Python

7th - 11th Grade

25 Qs

Python - lists,loops,basics

Python - lists,loops,basics

9th - 11th Grade

20 Qs

Python outputs

Python outputs

7th - 11th Grade

20 Qs

Basic Python

Basic Python

University

20 Qs

Python basics yr7

Python basics yr7

6th - 9th Grade

20 Qs

Python Basics ;)

Python Basics ;)

11th Grade

20 Qs

Python 2

Python 2

Assessment

Quiz

Computers

9th Grade

Easy

Created by

Ayorinde Omojuwa

Used 1+ times

FREE Resource

23 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which python operator means 'less than or equal to'?
>
<
>=
<=

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The correct way to convert user input is:

birth_year = number(input())

birth_year = int(input())

birth_year = (input(int))

birth_year = int(input)

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output for the following code?

100

50

20

130

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

What is the purpose of variables in Python?

Variables in Python are used to store data values for later use.

Variables in Python are used for decoration purposes only.

Variables in Python are used to perform mathematical operations.

Variables in Python are used to confuse the programmer.

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you declare a variable in Python?

variable_name = value

variable_name : value

variable_name = value =

value = variable_name

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What are the different types of conditional statements in Python?

when

unless

otherwise

if, elif, else

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax for an if statement in Python?

if (condition) then

if condition:

if (condition):

if condition then:

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?