7.5 Search Algorithms

7.5 Search Algorithms

12th Grade

14 Qs

quiz-placeholder

Similar activities

Computer Science Quiz

Computer Science Quiz

KG - Professional Development

18 Qs

Code.org Unit 7 Test

Code.org Unit 7 Test

10th - 12th Grade

18 Qs

DIGITAL MARKETING WITH AI🤖

DIGITAL MARKETING WITH AI🤖

9th - 12th Grade

10 Qs

Linear Search

Linear Search

12th Grade

10 Qs

AP CSP - Unit 6: Lesson 6: Assessment Day

AP CSP - Unit 6: Lesson 6: Assessment Day

12th Grade

15 Qs

SDD Test

SDD Test

10th - 12th Grade

15 Qs

Quiz Ôn tập

Quiz Ôn tập

7th Grade - University

18 Qs

AP CSP Code.org

AP CSP Code.org

9th - 12th Grade

17 Qs

7.5 Search Algorithms

7.5 Search Algorithms

Assessment

Quiz

Computers

12th Grade

Medium

Created by

Jennifer Greene

Used 8+ times

FREE Resource

14 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

10 sec • 1 pt

When can a Linear Search be performed?

On letters

On numbers

Both

None of these

2.

MULTIPLE CHOICE QUESTION

10 sec • 1 pt

In order to use a Binary Search, the data must be...

int's or doubles

either int's or Strings

in order

objects

3.

MULTIPLE CHOICE QUESTION

10 sec • 1 pt

True or False: Linear Search becomes more efficient as more values are added to a particular data set.

True

False

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

How does Linear Search work?

Linear Search traverses an array, starting at the first element, until the desired value is found, or until the end of the array.

Linear Search traverses an array from the last value to the first value until the desired value is found.

Linear Search uses a while loop to traverse an array for the desired value, or until the end of the array.

Linear Search searches for desired values by searching the next highest value in an array, and seeing if that is the desired value.

5.

MULTIPLE CHOICE QUESTION

20 sec • 1 pt

In a list with 100 items, how many comparisons are required by Sequential Search to determine that an item is not in the list?

50

100

It may result in an infinite loop

Not enough information to determine

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many iterations does Binary Search require to search a list with 32 items?

3

5

7

It depends on whether the item is found or not.

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the best description of the linear search algorithm?
Put the elements in order, then go through them one by one until target is found or the end of the list is reached.
Put the elements in order, compare with the middle value, if not the target: continue to the left or right of the middle and repeat. 
Elements do not need to be in order. Go through them one by one until target is found or the end of the list is reached.
Elements do not need to be in order, compare with the middle value, if not the target: continue to the left or right of the middle and repeat. 

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?