
TEST -BÀI 24 XÂU KÍ TỰ

Quiz
•
Computers
•
10th Grade
•
Hard
Thìn Lê
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Trong Python, câu lệnh nào dùng để tính độ dài của xâu s?
len(s)
length(s)
s.len()
s. length()
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Có bao nhiêu xâu kí tự hợp lệ?
1) “123_@##”
2) “hoa hau”
3) “346h7g84jd”
4) python
5) “01028475”
6) 123456
3
4
5
6
Answer explanation
Các xâu hợp lệ: 1, 2, 3, 5
Xâu kí tự trong Python là dãy các kí tự Unicode và được đặt trong cặp dấu nháy đơn hoặc nháy kép.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Xâu “1234%^^%TFRESDRG” có độ dài bằng bao nhiêu?
15
16
17
18
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Phát biểu nào sau đây là sai?
Có thể truy cập từng kí tự của xâu thông qua chỉ số.
Chỉ số bắt đầu từ 0.
Có thể thay đổi từng kí tự của một xâu.
Python không có kiểu dữ liệu kí tự.
Answer explanation
Khác với danh sách, không thể thay đổi từng kí tự trong xâu.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Sau khi thực hiện lệnh sau, biến s sẽ có kết quả là:
"3986443"
"8644"
"39864"
"443"
Answer explanation
Chương trình hiển thị chuỗi gồm các chữ số chẵn trong s1.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
S1 = “12345”
S2 = “3e4r45”
S3 = “45”
Biểu thức sau cho kết quả đúng hay sai?
S3 in S1
S3 in S2
True, False
True, True
False, False
False, True
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Kết quả của chương trình sau nếu s = “python1221” là gì?
True.
False.
1221
"2" và "1"
Create a free account and access millions of resources
Similar Resources on Wayground
15 questions
Bài 16. Ngôn ngữ lập trình bậc cao và python

Quiz
•
10th Grade
12 questions
BAI 25_TINHOC

Quiz
•
10th Grade
8 questions
TRÒ CHƠI HỎI NHANH ĐÁP GỌN

Quiz
•
10th Grade
10 questions
TRẮC NGHIỆM PYTHON

Quiz
•
9th - 12th Grade
9 questions
TIN 10_KTTX LẦN 3_15/4/2023

Quiz
•
10th Grade
10 questions
G10.W20 - Review biến, lệnh gán, lệnh print

Quiz
•
10th Grade
15 questions
Ôn tập Python

Quiz
•
9th - 12th Grade
10 questions
phu dao tin 10 thang 3

Quiz
•
10th Grade
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition

Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12

Lesson
•
11th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Computers
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
10 questions
Proper Keyboarding Techniques

Interactive video
•
6th - 10th Grade
10 questions
Understanding Computers: Hardware, Software, and Operating Systems

Interactive video
•
7th - 12th Grade
29 questions
AP CSP Unit 2 Review (Code.org)

Quiz
•
10th - 12th Grade