Kiểm tra kiến thức Python
Quiz
•
Computers
•
10th Grade
•
Practice Problem
•
Medium
Kha Phan
Used 9+ times
FREE Resource
Enhance your content in a minute
65 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cho mảng a=[0,2,4,6]. Phần tử a[1]=?
0
2
4
6
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Python cung cấp hàm để đếm số kí tự trong một xâu kể cả kí tự dấu cách
len()
dem()
high()
length()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Xâu rỗng là xâu
Có duy nhất một phần tử.
Viết theo chiều thuận và chiều ngược giống nhau.
Không có phần tử nào.
Có độ dài vô hạn.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cho xâu a = 'Lý Tự Trọng! Đây là trường của em!'. Để in cụm từ 'trường' từ xâu a, ta sử dụng lệnh nào
print(b = a[21:26])
print(a[21:26])
print(a[‘trường’])
print(b = a[21:25])
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cho trước xâu kí tự S và xâu substr. Dùng các lệnh nào để biết được vị trí xuất hiện cuối cùng của xâu substr trong xâu S? Ví dụ nếu S = '123321243212', Substr = '12' thì vị trí xuất hiện lần cuối của '12' trong xâu S sẽ là 10. Nếu không thấy sẽ trả về -1
n = len(S)
m = len(substr)
k = -1
for i in range(n-m):
if S.find(substr,i) >= 0:
k = S.find(substr,i)
print(k)
n = lenght(S)
m = lenght(substr)
k = -1
for i in range(n-m):
if S.find(substr,i) >= 0:
k = S.find(substr,i)
print(k)
n = lenght(S)
m = lenght(substr)
k = -1
for i in range(m-n):
if S.find(substr,i) >= 0:
k = S.find(substr,i)
print(k)
n = len(S)
m = len(substr)
k = -1
for i in range(m):
if S.find(substr,i) >= 0:
k = S.find(substr,i)
i = i + 1
print(k)
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cho danh sách a gồm các phần tử [3,4,5]. Khi đó len(a)=
2
3
1
4
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Mục đích của việc kiểm thử chương trình là
Xác định lại bài toán.
Phát hiện và sửa lỗi.
Mô tả chi tiết bài toán.
Để tạo ra một chương trình mới
Create a free account and access millions of resources
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
69 questions
Câu hỏi trắc nghiệm về Python
Quiz
•
10th Grade
65 questions
DIAGNOSTICO DE MANTENIMIENTO DE COMPUTADORAS
Quiz
•
10th Grade
60 questions
E-BOOK
Quiz
•
KG - University
61 questions
3. Hardware - Computer Architecture: Computer Science CIE IGCSE
Quiz
•
10th Grade
61 questions
Тестовый
Quiz
•
7th Grade - University
65 questions
Unit 7: Parameters, Return, & Libraries (APCSP '23-'24)
Quiz
•
9th - 12th Grade
60 questions
CK1 Tin 10
Quiz
•
10th Grade
66 questions
ÔN TẬP CUỐI HK2 TIN 10 NH 2024-2025
Quiz
•
10th Grade
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
15 questions
4:3 Model Multiplication of Decimals by Whole Numbers
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
The Best Christmas Pageant Ever Chapters 1 & 2
Quiz
•
4th Grade
12 questions
Unit 4 Review Day
Quiz
•
3rd Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
