Ôn tập cuối kỳ 2 Python

Quiz
•
Education
•
1st Grade
•
Medium
Huệ Bình Huỳnh
Used 13+ times
FREE Resource
50 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để khai báo biến Lop là kiểu dữ liệu kiểu xâu thì cách khai báo nào dưới đây là đúng:
Lop = 10
Lop = 10A1
Lop = “10A1”
Lop = 10.1
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để đo độ dài một biến xâu TruongHoc ta dùng hàm:
count(TruongHoc)
len(TruongHoc)
TruongHoc.upper()
Ten.find(Truonghoc)
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Hàm nào là đúng nhất để thay thế xâu con x1=“Pascal” trong xâu Lt = “Lập trình Pascal” thành “Python”?
Lt.count(x1, x2)
Lt.find(x1, x2)
Lt.replace(x1, x2)
len(Lt)
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Có bao nhiêu xâu kí tự KHÔNG nào hợp lệ?
1) “THPT Nguyễn Hiền”
2) “123” cố gắng học tập
3) “lập trình thật thú vị”
4) python
5) “02042023”
6) 123456
3
2
1
4
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để tìm vị trí đầu tiên xuất hiện xâu TenLot = “Thị” trong xâu HoTenHS nếu xâu “Thị” không xuất hiện trong xâu HoTenHS thì kết quả trả về là -1 , ta dùng hàm:
HoTenHS.count(TenLot)
TenLot.count(HoTenHS)
HoTenHS.find(TenLot)
TenLot.find(HoTenHS)
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để đếm số lần xuất hiện không giao nhau của xâu TenLot trong xâu HoTen, ta dùng hàm:
HoTen.count(TenLot)
TenLot.count(HoTen)
HoTen.find(TenLot)
TenLot.find(HoTen)
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Kết quả của chương trình sau là bao nhiêu?
Lt = “Lập trình Python”
print(len(Lt))
3
14
15
16
Create a free account and access millions of resources
Similar Resources on Wayground
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 Education
18 questions
D189 1st Grade OG 1c Concept 37-38

Quiz
•
1st Grade
20 questions
addition

Quiz
•
1st - 3rd Grade
20 questions
Subject and predicate in sentences

Quiz
•
1st - 3rd Grade
20 questions
Addition and Subtraction facts

Quiz
•
1st - 3rd Grade
20 questions
Place Value

Quiz
•
KG - 3rd Grade
10 questions
Exploring Properties of Matter

Interactive video
•
1st - 5th Grade
5 questions
Life at a pond

Quiz
•
1st Grade
14 questions
Plural Nouns Adding s and es

Quiz
•
1st - 2nd Grade