Search Header Logo

Câu hỏi về xâu ký tự trong Python

Authored by tranduy center-com

Other

1st Grade

Used 1+ times

Câu hỏi về xâu ký tự trong Python
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Xâu ký tự (chuỗi) trong lập trình là gì?

Một dãy các số nguyên

Một dãy các ký tự liên tiếp nhau

Một biến lưu trữ duy nhất một ký tự

Một kiểu dữ liệu chỉ chứa số thực

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Trong Python, ký hiệu nào được sử dụng để biểu diễn một xâu ký tự?

"" hoặc ''

[]

{}

()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Kết quả của biểu thức sau trong Python là gì? s = "Tin hoc 10" print(len(s))

8

9

10

11

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Cho đoạn mã sau: s = "TinHoc10" print(s[3]) Kết quả của chương trình là:

H

h

o

c

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Đâu là cách đúng để nối hai chuỗi "Hello" và "World" trong Python?

"Hello" + "World"

"Hello" . "World"

concat("Hello", "World")

"Hello" * "World"

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Ký tự nào dùng để xuống dòng trong chuỗi?

\t

\n

\\

\r

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Trong Python, phương thức nào được dùng để biến chuỗi "hello" thành "HELLO"?

upper()

lower()

capitalize()

title()

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

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

Already have an account?