
Bộ 4: Python cơ bản: variable, for loop, if-elif-else
Flashcard
•
Information Technology (IT)
•
University
•
Practice Problem
•
Hard
Wayground Content
FREE Resource
Student preview

14 questions
Show all answers
1.
FLASHCARD QUESTION
Front
Trong Python, lệnh nào dùng để gán giá trị 10 cho biến x?
Back
x = 10
Answer explanation
Để gán giá trị cho biến x, dùng dấu = trong Python
2.
FLASHCARD QUESTION
Front
Trong Python, lệnh nào sau đây dùng để kiểm tra nếu x lớn hơn 5?
Back
if x > 5:
Answer explanation
Dấu > được dùng để so sánh lớn hơn trong Python
3.
FLASHCARD QUESTION
Front
Trong Python, range(5) tạo ra dãy số nào?
Back
0, 1, 2, 3, 4
Answer explanation
range(5) trả về các giá trị từ 0 đến 4
4.
FLASHCARD QUESTION
Front
Trong Python, câu lệnh nào đúng để in từng ký tự trong chuỗi s?
Back
for c in s:
Answer explanation
for c in s duyệt qua từng ký tự trong chuỗi s
5.
FLASHCARD QUESTION
Front
Phép so sánh nào dùng để kiểm tra x khác 0 trong Python?
Back
x != 0
Answer explanation
Trong Python, != được dùng để so sánh khác
6.
FLASHCARD QUESTION
Front
Kết quả của biểu thức 3 * 2 ** 2 là gì?
Back
3 * (2 ** 2) = 12
Answer explanation
2 ** 2 = 4, khi nhân với 3, kết quả là 12
7.
FLASHCARD QUESTION
Front
Điều kiện nào đúng để kiểm tra n nằm trong khoảng [1, 10]? Options: if 1 <= n and n <= 10:, if 1 <= n <= 10:, if n in range(1,10):, if n in [1..10]:
Back
if 1 <= n <= 10:
Answer explanation
Trong Python có thể viết gộp: if 1 <= n <= 10
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
10 questions
Seasonal Menu
Flashcard
•
KG
7 questions
Chia thì tính từ
Flashcard
•
KG
7 questions
VẬN DỤNG TƯ TƯỞNG HỒ CHÍ MINH VỀ VĂN HÓA
Flashcard
•
University
10 questions
Trắc nghiệm Lịch sử Việt Nam
Flashcard
•
Professional Development
10 questions
Minigame
Flashcard
•
Professional Development
10 questions
Minecraft
Flashcard
•
KG
10 questions
Luyện tập- Chủ đề chung
Flashcard
•
KG
10 questions
Minería de Datos
Flashcard
•
University
Popular Resources on Wayground
10 questions
Honoring the Significance of Veterans Day
Interactive video
•
6th - 10th Grade
9 questions
FOREST Community of Caring
Lesson
•
1st - 5th Grade
10 questions
Exploring Veterans Day: Facts and Celebrations for Kids
Interactive video
•
6th - 10th Grade
19 questions
Veterans Day
Quiz
•
5th Grade
14 questions
General Technology Use Quiz
Quiz
•
8th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Circuits, Light Energy, and Forces
Quiz
•
5th Grade
19 questions
Thanksgiving Trivia
Quiz
•
6th Grade
Discover more resources for Information Technology (IT)
20 questions
Definite and Indefinite Articles in Spanish (Avancemos)
Quiz
•
8th Grade - University
7 questions
Force and Motion
Interactive video
•
4th Grade - University
9 questions
Principles of the United States Constitution
Interactive video
•
University
18 questions
Realidades 2 2A reflexivos
Quiz
•
7th Grade - University
10 questions
Dichotomous Key
Quiz
•
KG - University
25 questions
Integer Operations
Quiz
•
KG - University
7 questions
What Is Narrative Writing?
Interactive video
•
4th Grade - University
20 questions
SER vs ESTAR
Quiz
•
7th Grade - University