Search Header Logo

Python While Loop Quiz

Authored by Vernon Leigh

Computers

9th Grade

Used 13+ times

Python While Loop Quiz
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

6 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does this `while` loop do?

a. Prints numbers from 0 to 4

b. Prints numbers from 1 to 5

c. Prints the value of `count` indefinitely

d. Raises an error

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does this code snippet do?

a. Prints even numbers from 10 down to 2

b. Prints odd numbers from 1 to 9

c. Prints even numbers from 10 to -∞

d. Results in an infinite loop

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What does this `while` loop print?

a. 0 1 2 3 4

b. 1 2 3 4 5

c. 0 1 2 3

d. Infinite loop of 0s

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which `while` loop correctly prints the first three multiples of 4?

Media Image
Media Image
Media Image
Media Image

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What is the output of this `while` loop?

a. 2 4 6

b. 2 4 6 8

c. 0 2 4 6

d. 2 4 8

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which `while` loop correctly prints the squares of numbers from 1 to 5?

Media Image
Media Image
Media Image
Media Image

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

Microsoft

Continue with Microsoft

or continue with

Facebook

Facebook

Apple

Apple

Others

Others

Already have an account?