Search Header Logo
Nested Loops

Nested Loops

Assessment

Presentation

Computers

9th - 10th Grade

Practice Problem

Medium

Created by

Timothy Dickinson

Used 39+ times

FREE Resource

2 Slides • 8 Questions

1

Computer Science

Nested Loops

Slide image

2

Multiple Choice

What is a loop called when it sits inside another loop?

1

Double loop

2

Child loop

3

Nested loop

4

Underling loop

3

Multiple Choice

True or False?


"Only FOR loops can be nested"

1

True

2

False

4

WHILE loops can be nested too!

...and not just loops can be nested! Think about IF statements!

5

Multiple Choice

In what order does code process information if it has a nested loop under another loop?

1

- The first loop iterates until it's finished

- The nested loop iterates once

- The first loop repeats itself and iterates until finished

- The nested loop once more

2

- The first loop iterates once

- The nested loop iterates until it's finished

- The first loop iterates once more

- The nested loop repeats itself and iterates until finished

3

- The first loop iterates once

- The nested loop iterates once

- The first loop repeats once more

- The nested loop once once more

4

- The first loop iterates until it's finished

- The nested loop iterates until it's finished

- Code finishes

6

Multiple Choice

Question image

<- What does this code do:

1

It will print:
one 1 on row 1
one 2 on row 2
one 3 on row 3
one 4 on row 4

2

It will print:
four 1s on row 1
three 2s on row 2
two 3s on row 3
one 4 on row 4

3

It will print:
four 1s on row 1
four 2s on row 2
four 3s on row 3
four 4s on row 4

4

It will print:
one 1 on row 1
two 2s on row 2
three 3s on row 3
four 4s on row 4

7

Multiple Select

Which of these are correct?

1
2
3

8

Multiple Choice

What does end="" do?

1

It appendeds printed items sit on the same line

2

It makes all printed data types go on their own lines

3

It does nothing. It's an error

4

It finishes the code

9

Multiple Select

Question image

<- What is this code missing?

1

Line 1

Missing colon

2

Line 2

Missing 'for'

3

Line 3

Missing equals sign

4

Line 3

Missing colon

10

Multiple Choice

True or False?


"If a list that has lists inside it, each item in those lists count as a single iteration"

1

True

2

False

Computer Science

Nested Loops

Slide image

Show answer

Auto Play

Slide 1 / 10

SLIDE