
Lý thuyết 1

Quiz
•
Instructional Technology
•
8th Grade
•
Medium
Hiên Đào
Used 2+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để hiển thị từng giá trị của mảng a có n phần tử trên 1 dòng: ta dùng lệnh nào?
For i in range(n): print(i, end=' ')
For i in range(n): print(a[i], end=' ')
For i in range(1,n+1): print(i, end=' ')
For i in range(1,n+1): print(a[i], end=' ')
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để hiển thị từng giá trị của mảng a có n phần tử trên n dòng: ta dùng lệnh nào?
For i in range(n): print(i)
For i in range(n): print(a[i], end=' ')
For i in range(n): print(i, end=' ')
For i in range(n): print(a[i])
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để hiển thị từng giá trị của mảng a có n phần tử trên n dòng: ta dùng lệnh nào?
for i in a: print(a[i])
for i in a: print(a[i], end=' ')
for i in a: print(i)
for i in a: print(i, end=' ')
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để đưa ra vị trí phần tử lớn nhất của mảng a có n phần tử ta dùng đoạn lệnh nào?
ma=a[0]
for i in range(1,n):
if ma<a[i]:
ma=a[i]
vt=i+1
print(i)
ma=a[0]
for i in range(1,n):
if ma>a[i]:
ma=a[i]
vt=i+1
print(i)
ma=a[0]
for i in range(1,n):
if ma<a[i]:
ma=a[i]
vt=i
print(i)
ma=a[0]
for i in range(1,n):
if ma>a[i]:
ma=a[i]
vt=i
print(i)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Để đưa ra vị trí phần tử nhỏ nhất của mảng a có n phần tử ta dùng đoạn lệnh nào?
ma=a[0]
for i in range(1,n):
if ma<a[i]:
ma=a[i]
vt=i+1
print(i)
ma=a[0]
for i in range(1,n):
if ma>a[i]:
ma=a[i]
vt=i+1
print(i)
ma=a[0]
for i in range(1,n):
if ma<a[i]:
ma=a[i]
vt=i
print(i)
ma=a[0]
for i in range(1,n):
if ma>a[i]:
ma=a[i]
vt=i
print(i)
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Đâu là thuật toán tìm tổng các ước của 1 số nguyên dương n?
t=0
for i in range(n):
if n%i==0:
t+=i
print(t)
t=0
for i in range(1,int(n**0.5)):
if n%i==0:
t+=i
print(t)
t=0
for i in range(1,int(n**0.5)+1):
if n%i==0:
t+=i
if i*i!=n:
t+=n//i
print(t)
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Đâu là Hàm kiểm tra số n có phải là số hoàn hảo?
def hh(n):
t=0
for i in range(n+1):
if n%i==0:
t+=i
return t==n:
def hh(n)
t=0
for i in range(1,int(n**0.5)+1):
if n%i==0:
t+=i
if i*i!=n:
t+=n//i
return t==n
def hh(n):
t=0
for i in range(1,int(n**0.5)+1):
if n%i==0:
t+=i
return t==n
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
MATEMÁTICAS 9

Quiz
•
8th Grade
5 questions
Looping Statment

Quiz
•
8th - 9th Grade
10 questions
Media and Information Literacy

Quiz
•
1st Grade - University
11 questions
Reading Interest Survey Upper Grades

Quiz
•
6th - 8th Grade
10 questions
python

Quiz
•
2nd Grade - University
7 questions
Using your smartphone

Quiz
•
8th Grade
11 questions
DATA ANALYSIS 101 (Formulas / Functions)

Quiz
•
8th - 9th Grade
15 questions
Act. Levers

Quiz
•
7th - 10th Grade
Popular Resources on Wayground
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
10 questions
Ice Breaker Trivia: Food from Around the World

Quiz
•
3rd - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
20 questions
ELA Advisory Review

Quiz
•
7th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
10 questions
Multiplication and Division Unknowns

Quiz
•
3rd Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Instructional Technology
20 questions
Brand Labels

Quiz
•
5th - 12th Grade
10 questions
Ice Breaker Trivia: Food from Around the World

Quiz
•
3rd - 12th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
20 questions
Figurative Language Review

Quiz
•
8th Grade
4 questions
End-of-month reflection

Quiz
•
6th - 8th Grade
20 questions
Distribute and Combine Like Terms

Quiz
•
7th - 9th Grade
20 questions
Physical and Chemical Changes

Quiz
•
8th Grade
22 questions
Newton's Laws of Motion

Lesson
•
8th Grade