
bài 28
Authored by Trịnh Thanh Thảo
Computers
11th Grade
Used 2+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Khi khai báo một biến trong phạm vi của một hàm, biến đó sẽ có phạm vi là gì?
Chỉ sử dụng được trong hàm đó
Có thể sử dụng trong bất kỳ hàm nào
Có thể sử dụng trong các tệp mã khác
Có phạm vi toàn cục
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Khi gọi một hàm với các tham số được truyền vào, kết quả trả về sẽ phụ thuộc vào gì?
Tên của hàm
Định nghĩa của biến trong hàm
Giá trị trả về từ hàm
Thứ tự tham số được truyền vào
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Trong đoạn mã dưới đây, lỗi gì xảy ra khi thực thi?
def func(a, b):
a = a + b
b = b + a
return a + b
print(func(1, 2))
Lỗi cú pháp
Lỗi giá trị không xác định
Lỗi NameError
Không có lỗi gì
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Phạm vi của biến n trong hàm func là gì?
Biến này có thể được sử dụng trong các hàm khác
Biến này chỉ có thể sử dụng trong hàm hiện tại
Biến này có thể sử dụng trong các khối mã ngoài hàm
Không thể xác định
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Kết quả trả về của hàm sau khi gọi func(10, 20) là gì?
def func(a, b):
a = a + b
b = b + a
return a + b
30
40
80
50
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Khi gọi hàm với biến a=1 và b=2 theo đoạn mã sau, giá trị trả về là gì?
def func(a, b):
a = a + b
b = b + a
return a + b
3
5
8
4
7.
FILL IN THE BLANK QUESTION
1 min • 1 pt
Điền vào chỗ trống trong đoạn mã sau để chương trình hoạt động chính xác:
def func(a, b):
a = ___ # Thực hiện phép cộng a và b
b = b + ___ # Cộng a và b vào b
return a + b
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
10 questions
Excel
Quiz
•
11th - 12th Grade
10 questions
Bài 25 tin 10
Quiz
•
9th Grade - University
14 questions
Kiểu dữ liệu xâu kí tự - xử lí xâu kí tự
Quiz
•
9th - 12th Grade
15 questions
Sinh hoạt lớp Tuần 7
Quiz
•
1st Grade - University
12 questions
Tin học 2
Quiz
•
11th Grade
13 questions
Python Fundamentals and Programming
Quiz
•
11th - 12th Grade
12 questions
Powerpoint Presentation Interface Quiz
Quiz
•
11th Grade
15 questions
untitled
Quiz
•
11th Grade - University
Popular Resources on Wayground
7 questions
History of Valentine's Day
Interactive video
•
4th Grade
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
15 questions
Valentine's Day Trivia
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
Discover more resources for Computers
18 questions
Valentines Day Trivia
Quiz
•
3rd Grade - University
20 questions
-AR -ER -IR present tense
Quiz
•
10th - 12th Grade
21 questions
Presidents Day Trivia
Quiz
•
6th - 12th Grade
10 questions
Valentine's Day: History and Modern Celebration
Interactive video
•
9th - 12th Grade
11 questions
Valentine's Day Trivia
Quiz
•
8th - 12th Grade
10 questions
Factor Quadratic Expressions with Various Coefficients
Quiz
•
9th - 12th Grade
10 questions
Evaluating Piecewise Functions Practice
Quiz
•
11th Grade
18 questions
Success Strategies
Quiz
•
9th - 12th Grade