
AP CSP - Unit Algorithms (2)

Quiz
•
Computers
•
9th Grade
•
Hard
Quốc Thư
Used 26+ times
FREE Resource
29 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
2 mins • 5 pts
A mathematician comes up with an algorithm to search a matrix for a value.
This table shows how many steps the algorithm requires for different matrix sizes:
Which function best describes how the number of steps changes as the matrix size (nnn) increases?
2/n
n/2
n
n2
2n
2.
MULTIPLE SELECT QUESTION
2 mins • 5 pts
Kora implements an algorithm for determining whether a list has duplicate values.
She counts the number of steps required by the algorithm for increasing list lengths and comes up with this table:
Based on the table, which of the following statements describe the run time for this algorithm?
The algorithm does not run in reasonable time.
The algorithm runs in polynomial time.
The algorithm runs in superpolynomial time.
The algorithm runs in reasonable time.
3.
MULTIPLE SELECT QUESTION
2 mins • 5 pts
One way to measure the efficiency of an algorithm is to count how many steps it requires for different input sizes and then use a function to describe how the number of steps increases in proportion to the input size.
The table below lists various efficiencies, where n represents the input size.
Categorize each efficiency as superpolynomial:
n2+6n
6n
6n6
62n^2
n/6
4.
MULTIPLE SELECT QUESTION
2 mins • 5 pts
Reese develops an algorithm to determine all the possible pizza topping combinations.
For a list of 3 possible toppings ("pepper", "pineapple", "mushroom"), their algorithm generates these combinations:
- pepper
- pineapple
- mushroom
- pepper, pineapple
- pepper, mushroom
- pineapple, mushroom
- pepper, pineapple, mushroom
They try out the algorithm on increasing numbers of toppings and record the number of steps it takes.
Their findings are summarized in this table:
Based on the table, which of the following statements describe the run time for this algorithm?
The algorithm runs in reasonable time.
The algorithm runs in superpolynomial time.
The algorithm runs in polynomial time.
The algorithm does not run in reasonable time.
5.
MULTIPLE CHOICE QUESTION
2 mins • 5 pts
A mathematician comes up with an algorithm for multiplying two matrices together.
This table shows how many steps the algorithm requires for different matrix sizes:
Which function best describes how the number of steps changes as the matrix size (n) increases?
1/n
n
n2
n3
2n
6.
MULTIPLE SELECT QUESTION
2 mins • 5 pts
Meredith implements a "graph coloring" algorithm, which comes up with colors for graph vertices such that no neighboring vertices share the same color.
The algorithm outputs graph colorings like this one:
Based on the table, which of the following statements describe the run time for this algorithm?
The algorithm runs in reasonable time.
The algorithm does not run in reasonable time.
The algorithm runs in superpolynomial time.
The algorithm runs in polynomial time.
7.
MULTIPLE CHOICE QUESTION
2 mins • 5 pts
Which of the following is the best description of parallel computing?
A computational model in which a program is broken into smaller subproblems, some of which are executed simultaneously.
The use of multiple computing devices to work on different parts of a problem.
The technology which powers online experiences with multiple simultaneous users, such as multi-player computer games.
The mechanism by which a computer can run multiple applications at once, by switching between them so quickly the user cannot tell.
Create a free account and access millions of resources
Similar Resources on Wayground
24 questions
Programming & data structures JEOPARDY!

Quiz
•
9th - 10th Grade
25 questions
Visual Programming

Quiz
•
5th - 12th Grade
25 questions
Programming and data structures revision

Quiz
•
9th - 10th Grade
24 questions
Understanding Algorithms and Phishing

Quiz
•
3rd Grade - University
25 questions
Do Now Quiz - Coding I

Quiz
•
9th - 12th Grade
30 questions
Unit 1 Summative Assessment

Quiz
•
9th - 12th Grade
30 questions
GCSE (9–1) CS 2.1 Algorithms

Quiz
•
9th - 11th Grade
25 questions
Sort and Search Algorithms

Quiz
•
9th Grade
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade