
Sorting Algorithms Quiz
Quiz
•
Computers
•
12th Grade
•
Practice Problem
•
Hard
DR MURTHY
Used 1+ times
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the worst-case time complexity of Selection Sort?
O(n)
O(n log n)
O(n^2)
O(log n)
Answer explanation
Selection Sort has a worst-case time complexity of O(n^2) due to its nested loops for finding the minimum element and swapping it with the current element.
2.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Which of the following is true for Selection Sort?
It is the most efficient sorting algorithm.
It improves time complexity by making only one exchange for every pass through the list.
It is more complex than Quick Sort.
It is significantly faster than Bubble Sort in practical scenarios.
Answer explanation
The correct choices are that Selection Sort improves time complexity by making only one exchange for every pass through the list and it is significantly faster than Bubble Sort in practical scenarios.
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which sorting algorithm builds the final sorted array one item at a time?
Bubble Sort
Selection Sort
Insertion Sort
Merge Sort
Answer explanation
Insertion Sort builds the final sorted array one item at a time by taking each element and inserting it into its correct position in the sorted array.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the best case time complexity of Bubble Sort?
O(n log n)
O(n^2)
O(n)
O(log n)
Answer explanation
Bubble Sort has a best case time complexity of O(n) when the array is already sorted, as it only requires one pass to check if any swaps are needed.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In which sorting technique is the entire list divided into two parts: the sorted part at the left end and the unsorted part at the right end?
Bubble Sort
Insertion Sort
Selection Sort
Quick Sort
Answer explanation
In Insertion Sort, the list is divided into two parts: the sorted part on the left and the unsorted part on the right, making it the correct choice for the given scenario.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which sorting algorithm repeatedly steps through the list, compares adjacent elements, and swaps them if they are in the wrong order?
Selection Sort
Merge Sort
Bubble Sort
Insertion Sort
Answer explanation
Bubble Sort repeatedly steps through the list, compares adjacent elements, and swaps them if they are in the wrong order, making it the correct choice for the given question.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How does Bubble Sort behave if the list is already sorted?
It does not perform any operations.
It performs a single pass through the list to confirm it is sorted.
It behaves the same way as if the list were unsorted.
It immediately recognizes the list is sorted and stops.
Answer explanation
The Bubble Sort algorithm will perform a single pass through the list to confirm it is already sorted, making it the correct choice.
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
14 questions
Sains Komputer Tingkatan 4 - 2.2.3 Menghasilkan gambar rajah
Quiz
•
1st Grade - Professio...
10 questions
Review
Quiz
•
9th - 12th Grade
15 questions
Cyber Security KS4
Quiz
•
8th - 12th Grade
11 questions
College Football
Quiz
•
5th - 12th Grade
15 questions
Excel
Quiz
•
10th - 12th Grade
10 questions
Scratch
Quiz
•
KG - Professional Dev...
10 questions
What is a program slides(6:16)
Quiz
•
8th - 12th Grade
10 questions
Java: repetition control structure for & while
Quiz
•
10th - 12th Grade
Popular Resources on Wayground
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
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
