Search Header Logo
Review of Array

Review of Array

Assessment

Presentation

Mathematics

9th - 12th Grade

Hard

Created by

Steven Howard

FREE Resource

3 Slides • 3 Questions

1

Python Arrays

By Steven Howard

2

Arrays

​So far we have only used variables to store 1 value, eg:

name = "Bob"

An array allows us to store multiple values in 1 variable. It is like a LIST. eg:

name = ["bob", "Sally", "Harry"]​

media

3

Open Ended

What is an array?

4

Multiple Choice

Which of these is an list?

1

fruit = ['apples', 'oranges', 'bananas']

2

fruit = "apples", "oranges", "bananas"

3

fruit = {"apples", "oranges", "bananas"}

4

fruit = ("apples", "oranges", "bananas")

5

Multiple Choice

What is the result of this code?

colors = ['Red' ,'Blue' ,'Yellow' ,'Red']

for i in colors:

print (i)

1

['Red', 'Blue', 'Yellow', 'Red']

2

Red ,Blue ,Yellow, Red

3

Red

Blue

Yellow

Red

4

0 Red

1 Blue

2 Yellow

3 Red

6

​You are already familiar with 1D arrays, which look like this:

​Names = ['Ann', 'Chloe', 'Dave', 'Eve', 'Helen', 'Jim']

​Ages = [13, 17, 15, 8, 16, 12]

​All the elements of a 1D array are on the same row/line

Python Arrays

By Steven Howard

Show answer

Auto Play

Slide 1 / 6

SLIDE