For and While Loops in Python

For and While Loops in Python

9th - 12th Grade

16 Qs

quiz-placeholder

Similar activities

Security and Ethics

Security and Ethics

9th - 12th Grade

17 Qs

CIA Mid-Term Review 1

CIA Mid-Term Review 1

9th - 10th Grade

17 Qs

flowol week 3

flowol week 3

9th - 12th Grade

17 Qs

Coding Quiz

Coding Quiz

6th - 10th Grade

15 Qs

2.3.1 Graph Traversal & Path Finding Algorithms

2.3.1 Graph Traversal & Path Finding Algorithms

12th Grade - University

20 Qs

Interstate Competition

Interstate Competition

7th - 10th Grade

11 Qs

3.8  Mengevaluasi Perangkat Eksternal / Peripheral (SisKom)

3.8 Mengevaluasi Perangkat Eksternal / Peripheral (SisKom)

10th Grade

20 Qs

PSTS Administrasi Infrastruktur Jaringan Kelas XII TKJ

PSTS Administrasi Infrastruktur Jaringan Kelas XII TKJ

12th Grade

20 Qs

For and While Loops in Python

For and While Loops in Python

Assessment

Quiz

Computers

9th - 12th Grade

Hard

Created by

Lauren Tan

Used 154+ times

FREE Resource

AI

Enhance your content in a minute

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

16 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

The program above

prints all the odd numbers between 1 and 20

prints all even numbers between 1 and 20

print all the odd numbers between 1 and 21

prints all the even numbers between 1 and 21

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

The equivalent of the above for loop using the while syntax would be

Media Image
Media Image
Media Image
Media Image

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

The above program prints

Numbers 1 to 10 in reverse order

Numbers 1 to 11 in reverse order

Numbers 1 to 10

Numbers 1 to 11

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

Look at the following code, what will it generate

1,2,3,4,5,6,7,8,9,10,11,12

0,1,2,3,4,5,6,7,8,9,10,11,12

1,2,3,4,5,6,7,8,9,10,11,12,13

0,1,2,3,4,5,6,7,8,9,10,11,12,13

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image
Media Image
Media Image
Media Image

1,2,3,4

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What best describes what is printed by the following code?

Prints the numbers 0 through 6

Prints

h

e

l

l

o

w

Prints the phrase "hello world!" 7 times

Prints "hello w" 7 times

7.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What best describes what is printed by the following code?

Prints the numbers 0 through 6

Prints

h

e

l

l

o

w

Prints the phrase "hello world!" 7 times

Prints "hello w" 7 times

Create a free account and access millions of resources

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?

Discover more resources for Computers