
Bài Xâu Kí Tự
Authored by Dũng Quốc Trần
Computers
10th Grade

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
15 questions
Show all answers
1.
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à:
s1 ="3986443"
s2 = ""
for ch in s1:
if int(ch) % 2 == 0:
s2 = s2 + ch print(s2)
3986443
8644
39864
443
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Biểu thức sau cho kết quả đúng hay sai?
S1 = “12345”
S2 = “3e4r45”
S3 = “45”
S3 in S1
S3 in S2
True, False.
True, True.
False, False.
False, True.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Kết quả của chương trình sau nếu s = “python1221” là gì?
s = input("Nhập xâu kí tự bất kì:")
kq = False
for i in range(len(s)-1):
if s[i] == "2" and s[i+1] == "1":
kq = True
break
True.
False.
Chương trình bị lỗi.
Vòng lặp vô hạn.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Chương trình sau cho kết quả là bao nhiêu?
name = "Codelearn"
print(name[0])
“C”.
“o”.
“c”.
Câu lệnh bị lỗi.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Kết quả của chương trình sau là bao nhiêu?
>>> s = “0123145”
>>> s[0] = ‘8’
>>> print(s[0])
‘8’.
‘0’.
‘1’.
Chương trình bị lỗi.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Kết quả của chương trình sau là bao nhiêu?
>>> s = “abcdefg”
>>> print(s[2])
‘c’.
‘b’.
‘a’.
‘d’
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cho xâu s = "lập trình Python"
Để in xâu s ra màn hình ta dùng đoạn chương trình:
for i in range(15):
print(s[i], end = '')
for i in range(len(s)):
print(s[i], end = '')
for i in range(len(s -1)):
print(s[i], end = '')
for i in range(len(s)-1):
print(s[i], end = '')
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
15 questions
Code.org Lesson 1-14
Quiz
•
9th - 12th Grade
14 questions
BÀI 14- THUẬT TOÁN TÌM KIẾM TUẦN TỰ
Quiz
•
6th Grade - University
11 questions
Câu hỏi ôn tập HKII_Tin học 6
Quiz
•
8th Grade - Professio...
10 questions
Lesson 01 Unit 1 Excel 2019/365 MOAC
Quiz
•
9th - 12th Grade
10 questions
Emerging technologies
Quiz
•
6th Grade - University
10 questions
BÀI 8. SẮP XẾP VÀ LỌC DỮ LIỆU
Quiz
•
1st - 12th Grade
10 questions
Microsoft Teams
Quiz
•
KG - 12th Grade
20 questions
Trắc nghiệm Tin 10-Chủ đề A
Quiz
•
10th - 11th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
29 questions
Alg. 1 Section 5.1 Coordinate Plane
Quiz
•
9th Grade
22 questions
fractions
Quiz
•
3rd Grade
11 questions
FOREST Effective communication
Lesson
•
KG
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade