Search Header Logo

Xâu 4

Authored by Edu TSmart

English

5th Grade

Used 90+ times

Xâu 4
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

25 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Chuỗi "Python".swapcase() trả về gì?

python

PYTHON

pYTHON

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Đoạn mã sau in ra gì?

C O D E

C

C D

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Câu lệnh if s.endswith("!"): trả về True khi nào?

s chứa dấu chấm than

s kết thúc bằng dấu !

s bắt đầu bằng dấu !

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Câu 5: Đoạn mã sau đếm số nguyên âm trong chuỗi là lệnh nào trong Python?

sum(1 for c in s if c in 'aeiou')

sum(1 for c in s if c in '0123456789')

sum(1 for c in s if c in '-0123456789')

sum(1 for c in s if c in '-')

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Cho đoạn mã sau:

3

5

2

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Để đảo chuỗi s = "abc" ta dùng lệnh?

s[::-1]

reversed(s)

Cả hai đúng

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Đoạn mã nào chuyển ký tự thường thành hoa bằng lặp?

for c in s: print(c.upper())

print(s.upper())

Cả hai đúng

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?