Python Programming Quiz

Python Programming Quiz

9th Grade

15 Qs

quiz-placeholder

Similar activities

Avaliação 9º anos

Avaliação 9º anos

9th Grade

10 Qs

Quiz Informatika 9.1

Quiz Informatika 9.1

9th Grade

20 Qs

Berpikir Komputasional Kelas 8

Berpikir Komputasional Kelas 8

8th Grade - University

20 Qs

Quiz o klawiaturze

Quiz o klawiaturze

6th Grade - University

10 Qs

Modulo 3 Clase 3

Modulo 3 Clase 3

9th - 12th Grade

10 Qs

Mengulang Materi Menuju PSAS

Mengulang Materi Menuju PSAS

9th Grade - University

18 Qs

Campeonato Brasileiro

Campeonato Brasileiro

9th Grade

15 Qs

Struktur Data 2

Struktur Data 2

9th Grade

20 Qs

Python Programming Quiz

Python Programming Quiz

Assessment

Quiz

Information Technology (IT)

9th Grade

Practice Problem

Medium

Created by

Fadi Fadi

Used 1+ 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 will be the output of this code? nums = [10, 20, 30] for i in range(len(nums)): nums[i] += 5 print(nums)

[15, 25, 35]

[10, 20, 30]

[5, 15, 25]

[15, 20, 30]

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the result of the following code? fruits = ["apple", "banana", "cherry"] for fruit in fruits: fruit = fruit.upper() print(fruits)

['APPLE', 'BANANA', 'CHERRY']

['apple', 'banana', 'cherry']

['Apple', 'Banana', 'Cherry']

['FRUIT', 'FRUIT', 'FRUIT']

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which statement will correctly append 100 to a list scores inside a while loop?

scores += 100

scores.append(100)

scores = append(100)

append(scores, 100)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will the following code print? nums = [2, 4, 6] total = 0 for num in nums: total += num print(total)

246

6

12

12.0

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many times will this loop run? x = 0 while x < 5: x += 1

4

5

6

Infinite

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which line will remove "orange" from the list below? fruits = ["apple", "orange", "banana"]

fruits.delete("orange")

remove.fruits("orange")

fruits.remove("orange")

fruits.pop("orange")

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does this code output? names = ["Ana", "Bob", "Cody"] for i in range(1, len(names)): print(names[i])

Ana, Bob

Bob, Cody

Ana, Cody

Cody, Ana

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?