
Тест по алгоритмам сортировки

Quiz
•
Information Technology (IT)
•
10th Grade
•
Medium
Марзия Сагиева
Used 3+ times
FREE Resource
7 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Сұрыптау алгоритмдері дегеніміз не?
Мәліметтерді сақтау әдісі
Мәліметтерді ретке келтіру әдісі
Мәліметтерді іздеу алгоритмі
Мәліметтерді шифрлау әдісі
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Bubble Sort алгоритмінің уақыт күрделілігі қандай?
O(n)
O(n²)
O(log n)
O(n log n)
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Қай сұрыптау әдісі ең жылдам деп есептеледі үлкен көлемдегі деректер үшін?
Bubble Sort
Selection Sort
Quick Sort
Insertion Sort
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Merge Sort қандай әдіс қолданылады?
Бөл және биле (Divide and Conquer)
Итеративті қайталау
Тікелей алмастыру
Кездейсоқ таңдау
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Insertion Sort алгоритмі қай жағдайда тиімді жұмыс істейді?
Мәліметтер толығымен реттелмегенде
Мәліметтер аз және ішінара реттелгенде
Мәліметтер үлкен болғанда
Мәліметтер қайталанғанда
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Төмендегі кодтың нәтижесі қандай болады?
arr = [64, 34, 25, 12, 22, 11, 90]
for i in range(len(arr)):
for j in range(0, len(arr)-i-1):
if arr[j] > arr[j+1]:
arr[j], arr[j+1] = arr[j+1], arr[j]
print(arr)
[90, 64, 34, 25, 22, 12, 11]
[11, 12, 22, 25, 34, 64, 90]
[64, 34, 25, 12, 22, 11, 90]
Қате пайда болады
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Quick Sort әдісін қолдана отырып, массивті сұрыптаңыз:
arr = [10, 7, 8, 9, 1, 5]
Мына функцияны қолданыңыз:
def quick_sort(arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quick_sort(left) + middle + quick_sort(right)
print(quick_sort(arr))
[10, 7, 8, 9, 1, 5]
[1, 5, 7, 8, 9, 10]
[5, 1, 7, 8, 9, 10]
[1, 10, 5, 7, 8, 9]
Similar Resources on Wayground
Popular Resources on Wayground
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
Discover more resources for Information Technology (IT)
10 questions
Video Games

Quiz
•
6th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade
6 questions
Rule of Law

Quiz
•
6th - 12th Grade
15 questions
ACT Math Practice Test

Quiz
•
9th - 12th Grade
18 questions
Hispanic Heritage Month

Quiz
•
KG - 12th Grade
10 questions
Would you rather...

Quiz
•
KG - University