Search Header Logo

TH10 CĐ5-BH23 Tiết 1

Authored by phutuctran 1

Information Technology (IT)

10th Grade

Used 5+ times

TH10 CĐ5-BH23 Tiết 1
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Trong Python, cú pháp nào sau đây dùng để tạo một danh sách rỗng?

list = ()

list = []

list = {}

list = ""

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Câu lệnh nào sau đây dùng để thêm phần tử vào cuối danh sách?

list.append(x)

list.insert(k, x)

list.add(x)

list.pus(x)

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Cho danh sách A = [1, 2, 3, 4, 5], câu lệnh A[1] = 10 có tác dụng gì?

Thêm phần tử 10 vào danh sách

Xóa phần tử thứ 2

Thay phần tử thứ 2 thành 10

Lỗi

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Câu lệnh nào sau đây dùng để xóa phần tử ở vị trí chỉ số 1 trong danh sách?

del list[1]

list.remove(1)

list.delete(1)

list[1] = 0

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Hàm nào sau đây trả về số lượng phần tử trong danh sách?

len(list)

count(list)

length(list)

size(list)

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

a = [10, 20, 30, 40]

a.insert(2, 25)

print(a)

Kết quả sau khi thực hiện đoạn mã trên là gì?

[10, 20, 25, 30, 40]

[10, 25, 20, 30, 40]

[10, 20, 30, 25, 40]

[25, 10, 20, 30, 40]

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Lệnh A.clear() có tác dụng gì?

Xóa danh sách A

Xóa toàn bộ dữ liệu của danh sách A

Sắp xếp danh sách A

Không có lệnh clear()

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?