True or false: If an array is already sorted, Linear Search / Sequential Search is more efficient than Binary Search.
Unit 8 Algorithms and Recursion Quiz

Quiz
•
Computers
•
9th - 12th Grade
•
Medium
Krista Dobbins
Used 20+ times
FREE Resource
18 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
True
False
2.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What must be true before performing a binary search?
The elements must be sorted.
It can only contain binary values.
The elements must be some sort of number (i.e. int, double, Integer)
There are no necessary conditions.
3.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Given this array:
1, 2, 4, 5, 6, 7, 8, 12, 14, 21, 22, 42, 53
How many comparisons are required to find 42 using the Binary Search?
3
2
10
5
4.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
Given this array:
1, 2, 4, 5, 6, 7, 8, 12, 14, 21, 22, 42, 53
How many comparisons are required to find 42 using the Linear Search / Sequential Search?
3
2
12
5
5.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
BMO the robot is programming a new game called “Open the box!” You give him a number and he tries to open a numbered box. He’s using Binary Search to accomplish this. Unfortunately, the boxes are not sorted. They are in the following order:
1, 3, 6, 9, 14, 10, 21
Which box can NEVER be found using binary search?
9
6
14
10
6.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
We are searching for an int key in a sorted int array that has n elements. Under what circumstances will Linear Search / Sequential Search be more efficient than Binary Search?
key is the last element in the array
key is in the middle of the array
n is very large
key is the first element in the array
key does not exist in the array
7.
MULTIPLE CHOICE QUESTION
1 min • 1 pt
What is the largest number of comparisons needed to perform a binary search on an array with 42 elements?
2
5
6
41
42
Create a free account and access millions of resources
Similar Resources on Quizizz
16 questions
Searching & Sorting Algorithms

Quiz
•
10th Grade - University
18 questions
Search & Sort Algorithms

Quiz
•
7th - 11th Grade
23 questions
Intro to Algorithms

Quiz
•
9th - 12th Grade
18 questions
AQA GCSE Computer Science - 3.1.4 Sorting Algorithms

Quiz
•
8th - 10th Grade
20 questions
Java 2 Quiz 9

Quiz
•
10th - 12th Grade
20 questions
iGCSE Computer Science: Problem Solving

Quiz
•
9th - 12th Grade
20 questions
Searching and Sorting

Quiz
•
10th - 12th Grade
20 questions
2.1 Algorithms

Quiz
•
10th - 12th Grade
Popular Resources on Quizizz
15 questions
Character Analysis

Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
10 questions
American Flag

Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension

Quiz
•
5th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25

Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers

Quiz
•
6th - 8th Grade
Discover more resources for Computers
17 questions
Chapter 12 - Doing the Right Thing

Quiz
•
9th - 12th Grade
30 questions
Linear Inequalities

Quiz
•
9th - 12th Grade
20 questions
Types of Credit

Quiz
•
9th - 12th Grade
20 questions
Taxes

Quiz
•
9th - 12th Grade
17 questions
Parts of Speech

Quiz
•
7th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression

Quiz
•
9th - 12th Grade
20 questions
Inequalities Graphing

Quiz
•
9th - 12th Grade
10 questions
Identifying equations

Quiz
•
KG - University