Search Header Logo

Python Lists Quiz

Authored by Elsayed Seleim

Computers

8th - 9th Grade

Python Lists Quiz
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax to create an empty list in Python?

my_list = list()

my_list = {}

my_list = [None]

my_list = []

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you access the first element of a list in Python?

list_name[0]

list_name.first()

list_name(1)

list_name.get(0)

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the position of the name 'Paula' in the following list: names = ["Marco","Phillip","Paula","Tommy"]

0

1

2

3

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Lists use _____ to access values

values

indexes

key values

keys

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider this list, what will be the output of the following: li=[1,2,3,4,3,2,1] print(li[3])

4

3

2

1

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you access the first element of a list in Python?

list_name[0]

list_name.first()

list_name(1)

list_name.get(0)

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of these collections defines a LIST?

{"numbers": "omar", "Ali": "Ahmed"}

["omar", "Ali": "Ahmed"]

("omar", "Ali": "Ahmed")

{"omar", "Ali": "Ahmed"}

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?