Python Arrays Quiz P7

Python Arrays Quiz P7

11th Grade

15 Qs

quiz-placeholder

Similar activities

Паскаль. Основные команды

Паскаль. Основные команды

8th - 11th Grade

10 Qs

Bài tập Tin học 11 (Tiết 6)

Bài tập Tin học 11 (Tiết 6)

11th Grade

13 Qs

ASJ_XII_UH1

ASJ_XII_UH1

1st - 12th Grade

15 Qs

Python Quiz For Starters

Python Quiz For Starters

3rd Grade - Professional Development

17 Qs

ICT Computer Basics pt1

ICT Computer Basics pt1

10th - 12th Grade

12 Qs

Email Lớp 6

Email Lớp 6

6th Grade - University

17 Qs

Kuis Webinar Cerdas Bertelekomunikasi OTP Fraud

Kuis Webinar Cerdas Bertelekomunikasi OTP Fraud

6th Grade - Professional Development

10 Qs

Kuis Dadakan ;)

Kuis Dadakan ;)

10th Grade - University

15 Qs

Python Arrays Quiz P7

Python Arrays Quiz P7

Assessment

Quiz

Computers

11th Grade

Practice Problem

Medium

DOK Level 1: Recall

Standards-aligned

Created by

Joe Cusack

Used 24+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the syntax to create an array in Python using the array module?

`array('i', [1, 2, 3])`

`array([1, 2, 3])`

`[1, 2, 3]`

`{'i': [1, 2, 3]}`

Tags

DOK Level 1: Recall

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you access the first element of a Python array named `arr`?

`arr[0]`

`arr[1]`

`arr(first)`

`first(arr)`

Tags

DOK Level 1: Recall

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to modify the second element in a Python array `arr` to the value 5?

`arr[1] = 5`

`arr(1) = 5`

`arr[2] = 5`

`modify(arr[1], 5)`

Tags

DOK Level 1: Recall

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you slice a Python array `arr` to get the first three elements?

`arr[0:2]`

`arr[0:3]`

`arr[:3]`

`arr[1:3]`

Tags

DOK Level 1: Recall

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which array method in Python is used to add an element at the end of an array?

`append()`

`extend()`

`insert()`

`add()`

Tags

DOK Level 1: Recall

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How do you access the last element of a Python array named `arr`?

`arr[-1]`

`arr[last]`

`arr[end]`

`last(arr)`

Tags

DOK Level 1: Recall

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to change the third element in a Python array `arr` to the string "Python"?

`arr[2] = "Python"`

`arr[3] = "Python"`

`arr[2] = Python`

`set(arr[2], "Python")`

Tags

DOK Level 1: Recall

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?