Search Algorithm Recap
Quiz
•
Computers
•
11th Grade
•
Medium
Mr McCallion
Used 1+ times
FREE Resource
6 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
How does a binary search algorithm work?
by randomly selecting elements from the search space until the target element is found or the search space is empty.
by comparing each element in the search space with the target element until a match is found or the search space is empty.
by repeatedly dividing the search space in half until the target element is found or the search space is empty.
by comparing the last element of the list first and then moving towards the desired element
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
How does a linear search algorithm work?
by randomly selecting elements from the search space until the target element is found or the search space is empty.
by comparing each element in the search space with the target element until a match is found or the search space is empty.
by repeatedly dividing the search space in half until the target element is found or the search space is empty.
by comparing the last element of the list first and then moving towards the desired element
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
When should you use a linear search algorithm instead of a binary search algorithm?
When the list is sorted.
When the list contains duplicate elements.
When the list is very large.
When the list is not sorted.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is a binary search algorithm used for?
A binary search algorithm is used to sort an array in ascending order.
A binary search algorithm is used to find the position of a target value within a sorted array.
A binary search algorithm is used to randomly select elements from a list or array.
A binary search algorithm is used to compare each element in a list or array with the target value.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
When should you use a binary search algorithm instead of a linear search algorithm?
When the list is sorted.
When the list contains duplicate elements.
When the list is very large.
When the list is not sorted.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
In python we implement an array with a:
variable
list
dictionary
string
Similar Resources on Wayground
10 questions
GCSE Computer Science 9-1: Sorting Algorithms
Quiz
•
10th Grade - University
10 questions
AP Computer Science Principles - Unit 6: Algorithms
Quiz
•
9th - 12th Grade
9 questions
C++ Quiz 5: Searching and Sorting Algorithms
Quiz
•
7th - 12th Grade
10 questions
CODE.ORG VOCABULARY 1
Quiz
•
6th - 12th Grade
10 questions
Ch Y11 sort/search
Quiz
•
11th Grade
11 questions
Problem Solving
Quiz
•
9th - 12th Grade
10 questions
Python - Lists and Elements
Quiz
•
9th - 12th Grade
10 questions
Search Algorithms
Quiz
•
9th - 12th Grade
Popular Resources on Wayground
10 questions
Video Games
Quiz
•
6th - 12th Grade
20 questions
Brand Labels
Quiz
•
5th - 12th Grade
15 questions
Core 4 of Customer Service - Student Edition
Quiz
•
6th - 8th Grade
15 questions
What is Bullying?- Bullying Lesson Series 6-12
Lesson
•
11th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
15 questions
Subtracting Integers
Quiz
•
7th Grade
22 questions
Adding Integers
Quiz
•
6th Grade
10 questions
Exploring Digital Citizenship Essentials
Interactive video
•
6th - 10th Grade
